summaryrefslogtreecommitdiffstats
path: root/drivers/kvm/x86_emulate.c
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2007-07-17 23:16:11 +1000
committerAvi Kivity <avi@qumranet.com>2007-10-13 10:18:18 +0200
commit1e3c5cb0d5a63b7169708614bfba0c7f25aa493e (patch)
tree55c1d3ded12dbacc2962a3406bcf5da3aa68a513 /drivers/kvm/x86_emulate.c
parent5eb549a085c3500f2b9d8b48d40393b6e50b68a9 (diff)
downloadtalos-obmc-linux-1e3c5cb0d5a63b7169708614bfba0c7f25aa493e.tar.gz
talos-obmc-linux-1e3c5cb0d5a63b7169708614bfba0c7f25aa493e.zip
KVM: Trivial: Make decode_register() static
I have shied away from touching x86_emulate.c (it could definitely use some love, but it is forked from the Xen code, and it would be more productive to cross-merge fixes). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Avi Kivity <avi@qumranet.com>
Diffstat (limited to 'drivers/kvm/x86_emulate.c')
-rw-r--r--drivers/kvm/x86_emulate.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/kvm/x86_emulate.c b/drivers/kvm/x86_emulate.c
index 4b8a0cc9665e..f5e4644e2437 100644
--- a/drivers/kvm/x86_emulate.c
+++ b/drivers/kvm/x86_emulate.c
@@ -443,8 +443,13 @@ struct operand {
(((reg) + _inc) & ((1UL << (ad_bytes << 3)) - 1)); \
} while (0)
-void *decode_register(u8 modrm_reg, unsigned long *regs,
- int highbyte_regs)
+/*
+ * Given the 'reg' portion of a ModRM byte, and a register block, return a
+ * pointer into the block that addresses the relevant register.
+ * @highbyte_regs specifies whether to decode AH,CH,DH,BH.
+ */
+static void *decode_register(u8 modrm_reg, unsigned long *regs,
+ int highbyte_regs)
{
void *p;
OpenPOWER on IntegriCloud