diff options
Diffstat (limited to 'arch/ia64/include/asm/paravirt_privop.h')
-rw-r--r-- | arch/ia64/include/asm/paravirt_privop.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/arch/ia64/include/asm/paravirt_privop.h b/arch/ia64/include/asm/paravirt_privop.h index d577aac11835..33c8e55f5775 100644 --- a/arch/ia64/include/asm/paravirt_privop.h +++ b/arch/ia64/include/asm/paravirt_privop.h | |||
@@ -78,6 +78,18 @@ extern unsigned long ia64_native_getreg_func(int regnum); | |||
78 | ia64_native_rsm(mask); \ | 78 | ia64_native_rsm(mask); \ |
79 | } while (0) | 79 | } while (0) |
80 | 80 | ||
81 | /* returned ip value should be the one in the caller, | ||
82 | * not in __paravirt_getreg() */ | ||
83 | #define paravirt_getreg(reg) \ | ||
84 | ({ \ | ||
85 | unsigned long res; \ | ||
86 | if ((reg) == _IA64_REG_IP) \ | ||
87 | res = ia64_native_getreg(_IA64_REG_IP); \ | ||
88 | else \ | ||
89 | res = pv_cpu_ops.getreg(reg); \ | ||
90 | res; \ | ||
91 | }) | ||
92 | |||
81 | /****************************************************************************** | 93 | /****************************************************************************** |
82 | * replacement of hand written assembly codes. | 94 | * replacement of hand written assembly codes. |
83 | */ | 95 | */ |