Skip to contentSkip to conversation

powerpc: add defintion for MSR[GS] to list of MSR bits

PATCH Superseded Timur Tabi 2 participants 3 messages Mar 2, 2009 – Mar 3, 2009 PowerPC

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Timur Tabi

author
#0 lore raw

PATCH 1/1 powerpc: add defintion for MSR[GS] to list of MSR bits

Add macros for the GS (guest state) bit to the list of MSR bit definitions. On PowerPC cores that support embedded hypervisor mode, GS is cleared if the system is running in hypervisor state (and MSR[PR] is cleared), and set if it's running in guest state. See the Power ISA 2.06 specification for more information.

---
 arch/powerpc/include/asm/reg.h |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
arch/powerpc/include/asm/reg.h +2 -0
index c6d1ab6..ca5c7f8 100644
@@ -29,6 +29,7 @@
 #define MSR_SF_LG	63              /* Enable 64 bit mode */
 #define MSR_ISF_LG	61              /* Interrupt 64b mode valid on 630 */
 #define MSR_HV_LG 	60              /* Hypervisor state */
+#define MSR_GS_LG	28		/* Guest state */
 #define MSR_VEC_LG	25	        /* Enable AltiVec */
 #define MSR_VSX_LG	23		/* Enable VSX */
 #define MSR_POW_LG	18		/* Enable Power Management */
@@ -71,6 +72,7 @@
 #define MSR_HV		0
 #endif
 
+#define MSR_GS		__MASK(MSR_GS_LG)	/* Guest state */
 #define MSR_VEC		__MASK(MSR_VEC_LG)	/* Enable AltiVec */
 #define MSR_VSX		__MASK(MSR_VSX_LG)	/* Enable VSX */
 #define MSR_POW		__MASK(MSR_POW_LG)	/* Enable Power Management */
Signature · 1 line
1.5.5
#1 lore raw

arch/powerpc/include/asm/reg.h

Quoted 12 lines

Add macros for the GS (guest state) bit to the list of MSR bit definitions. On PowerPC cores that support embedded hypervisor mode, GS is cleared if the system is running in hypervisor state (and MSR[PR] is cleared), and set if it's running in guest state. See the Power ISA 2.06 specification for more information.

---
 arch/powerpc/include/asm/reg.h |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
arch/powerpc/include/asm/reg.h +0 -0

Shouldn't this be in reg_booke.h?

Mikey

Quoted 12 lines

index c6d1ab6..ca5c7f8 100644

arch/powerpc/include/asm/reg.h +1 -0
@@ -29,6 +29,7 @@
 #define MSR_SF_LG	63              /* Enable 64 bit mode */
 #define MSR_ISF_LG	61              /* Interrupt 64b mode valid on 630 */
 #define MSR_HV_LG 	60              /* Hypervisor state */
+#define MSR_GS_LG	28		/* Guest state */
 #define MSR_VEC_LG	25	        /* Enable AltiVec */
 #define MSR_VSX_LG	23		/* Enable VSX */
 #define MSR_POW_LG	18		/* Enable Power Management */

arch/powerpc/include/asm/reg.h line 78

Quoted 7 lines
arch/powerpc/include/asm/reg.h +1 -0
@@ -71,6 +72,7 @@
 #define MSR_HV		0
 #endif
 
+#define MSR_GS		__MASK(MSR_GS_LG)	/* Guest state */
 #define MSR_VEC		__MASK(MSR_VEC_LG)	/* Enable AltiVec */
 #define MSR_VSX		__MASK(MSR_VSX_LG)	/* Enable VSX */
 #define MSR_POW		__MASK(MSR_POW_LG)	/* Enable Power Managem

ent */

Quoted 8 lines
Signature · 6 lines
1.5.5

_______________________________________________
Linuxppc-dev mailing list
[email protected]
https://ozlabs.org/mailman/listinfo/linuxppc-dev
author
#2 lore raw
Quoted 3 lines · Michael Neuling

arch/powerpc/include/asm/reg.h

Quoted 1 line
arch/powerpc/include/asm/reg.h +0 -0

Shouldn't this be in reg_booke.h?

Yes, you're right.

Signature · 2 lines
Timur Tabi
Linux Kernel Developer @ Freescale