Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
Kernel
提交
5b9f69ff
K
Kernel
项目概览
openeuler
/
Kernel
大约 2 年 前同步成功
通知
8
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
Kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
5b9f69ff
编写于
10月 29, 2021
作者:
M
Michael Ellerman
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'topic/ppc-kvm' into next
Merge a couple of KVM ppc patches we are keeping in a topic branch.
上级
19b27f37
235cee16
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
56 addition
and
3 deletion
+56
-3
arch/powerpc/include/asm/kvm_book3s_64.h
arch/powerpc/include/asm/kvm_book3s_64.h
+4
-0
arch/powerpc/kvm/book3s_hv.c
arch/powerpc/kvm/book3s_hv.c
+28
-2
arch/powerpc/kvm/book3s_hv_rm_mmu.c
arch/powerpc/kvm/book3s_hv_rm_mmu.c
+9
-0
arch/powerpc/kvm/booke.c
arch/powerpc/kvm/booke.c
+15
-1
未找到文件。
arch/powerpc/include/asm/kvm_book3s_64.h
浏览文件 @
5b9f69ff
...
...
@@ -378,6 +378,10 @@ static inline unsigned long compute_tlbie_rb(unsigned long v, unsigned long r,
rb
|=
1
;
/* L field */
rb
|=
r
&
0xff000
&
((
1ul
<<
a_pgshift
)
-
1
);
/* LP field */
}
/*
* This sets both bits of the B field in the PTE. 0b1x values are
* reserved, but those will have been filtered by kvmppc_do_h_enter.
*/
rb
|=
(
v
>>
HPTE_V_SSIZE_SHIFT
)
<<
8
;
/* B field */
return
rb
;
}
...
...
arch/powerpc/kvm/book3s_hv.c
浏览文件 @
5b9f69ff
...
...
@@ -3726,7 +3726,20 @@ static noinline void kvmppc_run_core(struct kvmppc_vcore *vc)
kvmppc_set_host_core
(
pcpu
);
guest_exit_irqoff
();
context_tracking_guest_exit
();
if
(
!
vtime_accounting_enabled_this_cpu
())
{
local_irq_enable
();
/*
* Service IRQs here before vtime_account_guest_exit() so any
* ticks that occurred while running the guest are accounted to
* the guest. If vtime accounting is enabled, accounting uses
* TB rather than ticks, so it can be done without enabling
* interrupts here, which has the problem that it accounts
* interrupt processing overhead to the host.
*/
local_irq_disable
();
}
vtime_account_guest_exit
();
local_irq_enable
();
...
...
@@ -4510,7 +4523,20 @@ int kvmhv_run_single_vcpu(struct kvm_vcpu *vcpu, u64 time_limit,
kvmppc_set_host_core
(
pcpu
);
guest_exit_irqoff
();
context_tracking_guest_exit
();
if
(
!
vtime_accounting_enabled_this_cpu
())
{
local_irq_enable
();
/*
* Service IRQs here before vtime_account_guest_exit() so any
* ticks that occurred while running the guest are accounted to
* the guest. If vtime accounting is enabled, accounting uses
* TB rather than ticks, so it can be done without enabling
* interrupts here, which has the problem that it accounts
* interrupt processing overhead to the host.
*/
local_irq_disable
();
}
vtime_account_guest_exit
();
local_irq_enable
();
...
...
arch/powerpc/kvm/book3s_hv_rm_mmu.c
浏览文件 @
5b9f69ff
...
...
@@ -207,6 +207,15 @@ long kvmppc_do_h_enter(struct kvm *kvm, unsigned long flags,
if
(
kvm_is_radix
(
kvm
))
return
H_FUNCTION
;
/*
* The HPTE gets used by compute_tlbie_rb() to set TLBIE bits, so
* these functions should work together -- must ensure a guest can not
* cause problems with the TLBIE that KVM executes.
*/
if
((
pteh
>>
HPTE_V_SSIZE_SHIFT
)
&
0x2
)
{
/* B=0b1x is a reserved value, disallow it. */
return
H_PARAMETER
;
}
psize
=
kvmppc_actual_pgsz
(
pteh
,
ptel
);
if
(
!
psize
)
return
H_PARAMETER
;
...
...
arch/powerpc/kvm/booke.c
浏览文件 @
5b9f69ff
...
...
@@ -1042,7 +1042,21 @@ int kvmppc_handle_exit(struct kvm_vcpu *vcpu, unsigned int exit_nr)
}
trace_kvm_exit
(
exit_nr
,
vcpu
);
guest_exit_irqoff
();
context_tracking_guest_exit
();
if
(
!
vtime_accounting_enabled_this_cpu
())
{
local_irq_enable
();
/*
* Service IRQs here before vtime_account_guest_exit() so any
* ticks that occurred while running the guest are accounted to
* the guest. If vtime accounting is enabled, accounting uses
* TB rather than ticks, so it can be done without enabling
* interrupts here, which has the problem that it accounts
* interrupt processing overhead to the host.
*/
local_irq_disable
();
}
vtime_account_guest_exit
();
local_irq_enable
();
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录