Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
648d453d
Commit
648d453d
authored
Sep 14, 2017
by
Radim Krčmář
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'kvm-ppc-fixes' of
git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc
Bug fixes for stable.
parents
a5f01f8e
67f8a8c1
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
22 additions
and
6 deletions
+22
-6
arch/powerpc/kvm/book3s_hv.c
arch/powerpc/kvm/book3s_hv.c
+2
-0
arch/powerpc/kvm/book3s_hv_rm_xive.c
arch/powerpc/kvm/book3s_hv_rm_xive.c
+0
-1
arch/powerpc/kvm/book3s_hv_rmhandlers.S
arch/powerpc/kvm/book3s_hv_rmhandlers.S
+16
-1
arch/powerpc/kvm/book3s_xive.c
arch/powerpc/kvm/book3s_xive.c
+0
-1
arch/powerpc/kvm/book3s_xive_template.c
arch/powerpc/kvm/book3s_xive_template.c
+4
-3
No files found.
arch/powerpc/kvm/book3s_hv.c
View file @
648d453d
...
...
@@ -4212,11 +4212,13 @@ static int kvmhv_configure_mmu(struct kvm *kvm, struct kvm_ppc_mmuv3_cfg *cfg)
if
((
cfg
->
process_table
&
PRTS_MASK
)
>
24
)
return
-
EINVAL
;
mutex_lock
(
&
kvm
->
lock
);
kvm
->
arch
.
process_table
=
cfg
->
process_table
;
kvmppc_setup_partition_table
(
kvm
);
lpcr
=
(
cfg
->
flags
&
KVM_PPC_MMUV3_GTSE
)
?
LPCR_GTSE
:
0
;
kvmppc_update_lpcr
(
kvm
,
lpcr
,
LPCR_GTSE
);
mutex_unlock
(
&
kvm
->
lock
);
return
0
;
}
...
...
arch/powerpc/kvm/book3s_hv_rm_xive.c
View file @
648d453d
...
...
@@ -38,7 +38,6 @@ static inline void __iomem *get_tima_phys(void)
#define __x_tima get_tima_phys()
#define __x_eoi_page(xd) ((void __iomem *)((xd)->eoi_page))
#define __x_trig_page(xd) ((void __iomem *)((xd)->trig_page))
#define __x_readb __raw_rm_readb
#define __x_writeb __raw_rm_writeb
#define __x_readw __raw_rm_readw
#define __x_readq __raw_rm_readq
...
...
arch/powerpc/kvm/book3s_hv_rmhandlers.S
View file @
648d453d
...
...
@@ -771,6 +771,9 @@ END_FTR_SECTION_IFCLR(CPU_FTR_ARCH_207S)
#ifdef CONFIG_PPC_TRANSACTIONAL_MEM
BEGIN_FTR_SECTION
/
*
*
NOTE
THAT
THIS
TRASHES
ALL
NON
-
VOLATILE
REGISTERS
INCLUDING
CR
*/
bl
kvmppc_restore_tm
END_FTR_SECTION_IFSET
(
CPU_FTR_TM
)
#endif
...
...
@@ -1630,6 +1633,9 @@ END_FTR_SECTION_IFCLR(CPU_FTR_ARCH_300)
#ifdef CONFIG_PPC_TRANSACTIONAL_MEM
BEGIN_FTR_SECTION
/
*
*
NOTE
THAT
THIS
TRASHES
ALL
NON
-
VOLATILE
REGISTERS
INCLUDING
CR
*/
bl
kvmppc_save_tm
END_FTR_SECTION_IFSET
(
CPU_FTR_TM
)
#endif
...
...
@@ -1749,7 +1755,10 @@ END_FTR_SECTION_IFSET(CPU_FTR_ARCH_300)
/
*
*
Are
we
running
hash
or
radix
?
*/
beq
cr2
,
3
f
ld
r5
,
VCPU_KVM
(
r9
)
lbz
r0
,
KVM_RADIX
(
r5
)
cmpwi
cr2
,
r0
,
0
beq
cr2
,
3
f
/
*
Radix
:
Handle
the
case
where
the
guest
used
an
illegal
PID
*/
LOAD_REG_ADDR
(
r4
,
mmu_base_pid
)
...
...
@@ -2466,6 +2475,9 @@ _GLOBAL(kvmppc_h_cede) /* r3 = vcpu pointer, r11 = msr, r13 = paca */
#ifdef CONFIG_PPC_TRANSACTIONAL_MEM
BEGIN_FTR_SECTION
/
*
*
NOTE
THAT
THIS
TRASHES
ALL
NON
-
VOLATILE
REGISTERS
INCLUDING
CR
*/
ld
r9
,
HSTATE_KVM_VCPU
(
r13
)
bl
kvmppc_save_tm
END_FTR_SECTION_IFSET
(
CPU_FTR_TM
)
...
...
@@ -2578,6 +2590,9 @@ kvm_end_cede:
#ifdef CONFIG_PPC_TRANSACTIONAL_MEM
BEGIN_FTR_SECTION
/
*
*
NOTE
THAT
THIS
TRASHES
ALL
NON
-
VOLATILE
REGISTERS
INCLUDING
CR
*/
bl
kvmppc_restore_tm
END_FTR_SECTION_IFSET
(
CPU_FTR_TM
)
#endif
...
...
arch/powerpc/kvm/book3s_xive.c
View file @
648d453d
...
...
@@ -48,7 +48,6 @@
#define __x_tima xive_tima
#define __x_eoi_page(xd) ((void __iomem *)((xd)->eoi_mmio))
#define __x_trig_page(xd) ((void __iomem *)((xd)->trig_mmio))
#define __x_readb __raw_readb
#define __x_writeb __raw_writeb
#define __x_readw __raw_readw
#define __x_readq __raw_readq
...
...
arch/powerpc/kvm/book3s_xive_template.c
View file @
648d453d
...
...
@@ -28,7 +28,8 @@ static void GLUE(X_PFX,ack_pending)(struct kvmppc_xive_vcpu *xc)
* bit.
*/
if
(
cpu_has_feature
(
CPU_FTR_POWER9_DD1
))
{
u8
pipr
=
__x_readb
(
__x_tima
+
TM_QW1_OS
+
TM_PIPR
);
__be64
qw1
=
__x_readq
(
__x_tima
+
TM_QW1_OS
);
u8
pipr
=
be64_to_cpu
(
qw1
)
&
0xff
;
if
(
pipr
>=
xc
->
hw_cppr
)
return
;
}
...
...
@@ -336,7 +337,6 @@ X_STATIC unsigned long GLUE(X_PFX,h_ipoll)(struct kvm_vcpu *vcpu, unsigned long
struct
kvmppc_xive_vcpu
*
xc
=
vcpu
->
arch
.
xive_vcpu
;
u8
pending
=
xc
->
pending
;
u32
hirq
;
u8
pipr
;
pr_devel
(
"H_IPOLL(server=%ld)
\n
"
,
server
);
...
...
@@ -353,7 +353,8 @@ X_STATIC unsigned long GLUE(X_PFX,h_ipoll)(struct kvm_vcpu *vcpu, unsigned long
pending
=
0xff
;
}
else
{
/* Grab pending interrupt if any */
pipr
=
__x_readb
(
__x_tima
+
TM_QW1_OS
+
TM_PIPR
);
__be64
qw1
=
__x_readq
(
__x_tima
+
TM_QW1_OS
);
u8
pipr
=
be64_to_cpu
(
qw1
)
&
0xff
;
if
(
pipr
<
8
)
pending
|=
1
<<
pipr
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment