summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2007-10-25 14:09:53 +1000
committerRusty Russell <rusty@rustcorp.com.au>2007-10-25 14:09:53 +1000
commit25c47bb35355c1e1b2ae325b49441b2c8b201ece (patch)
treeb716ffc014c32fa5f7ba391ad44ee330bdaf72b2 /arch
parentdb24e8c2ef7eceb46818a8c22fc38dea733fe159 (diff)
downloadlinux-25c47bb35355c1e1b2ae325b49441b2c8b201ece.tar.gz
linux-25c47bb35355c1e1b2ae325b49441b2c8b201ece.tar.bz2
linux-25c47bb35355c1e1b2ae325b49441b2c8b201ece.zip
lguest: use defines from x86 headers instead of magic numbers
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'arch')
-rw-r--r--arch/x86/lguest/boot.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/arch/x86/lguest/boot.c b/arch/x86/lguest/boot.c
index d2235db4085f..136d9df0295e 100644
--- a/arch/x86/lguest/boot.c
+++ b/arch/x86/lguest/boot.c
@@ -371,8 +371,7 @@ static void lguest_cpuid(unsigned int *eax, unsigned int *ebx,
static unsigned long current_cr0, current_cr3;
static void lguest_write_cr0(unsigned long val)
{
- /* 8 == TS bit. */
- lazy_hcall(LHCALL_TS, val & 8, 0, 0);
+ lazy_hcall(LHCALL_TS, val & X86_CR0_TS, 0, 0);
current_cr0 = val;
}
@@ -387,7 +386,7 @@ static unsigned long lguest_read_cr0(void)
static void lguest_clts(void)
{
lazy_hcall(LHCALL_TS, 0, 0, 0);
- current_cr0 &= ~8U;
+ current_cr0 &= ~X86_CR0_TS;
}
/* CR2 is the virtual address of the last page fault, which the Guest only ever