* [PATCH] powerpc: add defintion for MSR[GS] to list of MSR bits
@ 2009-03-02 18:20 Timur Tabi
2009-03-03 1:02 ` Michael Neuling
0 siblings, 1 reply; 3+ messages in thread
From: Timur Tabi @ 2009-03-02 18:20 UTC (permalink / raw)
To: linuxppc-dev, benh
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.
Signed-off-by: Timur Tabi <timur@freescale.com>
---
arch/powerpc/include/asm/reg.h | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/arch/powerpc/include/asm/reg.h b/arch/powerpc/include/asm/reg.h
index c6d1ab6..ca5c7f8 100644
--- a/arch/powerpc/include/asm/reg.h
+++ b/arch/powerpc/include/asm/reg.h
@@ -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 */
--
1.5.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] powerpc: add defintion for MSR[GS] to list of MSR bits
2009-03-02 18:20 [PATCH] powerpc: add defintion for MSR[GS] to list of MSR bits Timur Tabi
@ 2009-03-03 1:02 ` Michael Neuling
2009-03-03 2:16 ` Timur Tabi
0 siblings, 1 reply; 3+ messages in thread
From: Michael Neuling @ 2009-03-03 1:02 UTC (permalink / raw)
To: Timur Tabi; +Cc: linuxppc-dev
> 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.
>
> Signed-off-by: Timur Tabi <timur@freescale.com>
> ---
> arch/powerpc/include/asm/reg.h | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/arch/powerpc/include/asm/reg.h b/arch/powerpc/include/asm/reg.h
Shouldn't this be in reg_booke.h?
Mikey
> index c6d1ab6..ca5c7f8 100644
> --- a/arch/powerpc/include/asm/reg.h
> +++ b/arch/powerpc/include/asm/reg.h
> @@ -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 Managem
ent */
> --
> 1.5.5
>
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev@ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-dev
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] powerpc: add defintion for MSR[GS] to list of MSR bits
2009-03-03 1:02 ` Michael Neuling
@ 2009-03-03 2:16 ` Timur Tabi
0 siblings, 0 replies; 3+ messages in thread
From: Timur Tabi @ 2009-03-03 2:16 UTC (permalink / raw)
To: Michael Neuling; +Cc: linuxppc-dev
Michael Neuling wrote:
>> diff --git a/arch/powerpc/include/asm/reg.h b/arch/powerpc/include/asm/reg.h
>
> Shouldn't this be in reg_booke.h?
Yes, you're right.
--
Timur Tabi
Linux Kernel Developer @ Freescale
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2009-03-03 2:16 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-03-02 18:20 [PATCH] powerpc: add defintion for MSR[GS] to list of MSR bits Timur Tabi
2009-03-03 1:02 ` Michael Neuling
2009-03-03 2:16 ` Timur Tabi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).