[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH 06/34] x86: fix two unused variable errors when !CONFIG_HVM
The one in context_switch is fixed by annotating with __maybe_unused because I want to keep prevd around. The other is fixed by eliminating v. Signed-off-by: Wei Liu <wei.liu2@xxxxxxxxxx> --- xen/arch/x86/domain.c | 3 ++- xen/arch/x86/mm/shadow/common.c | 3 +-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/xen/arch/x86/domain.c b/xen/arch/x86/domain.c index 5bb900e..574bdf0 100644 --- a/xen/arch/x86/domain.c +++ b/xen/arch/x86/domain.c @@ -1671,7 +1671,8 @@ static void __context_switch(void) void context_switch(struct vcpu *prev, struct vcpu *next) { unsigned int cpu = smp_processor_id(); - const struct domain *prevd = prev->domain, *nextd = next->domain; + const struct domain * __maybe_unused prevd = prev->domain, + *nextd = next->domain; unsigned int dirty_cpu = next->dirty_cpu; ASSERT(local_irq_is_enabled()); diff --git a/xen/arch/x86/mm/shadow/common.c b/xen/arch/x86/mm/shadow/common.c index fd42d73..0856650 100644 --- a/xen/arch/x86/mm/shadow/common.c +++ b/xen/arch/x86/mm/shadow/common.c @@ -430,10 +430,9 @@ const struct x86_emulate_ops *shadow_init_emulation( void shadow_continue_emulation(struct sh_emulate_ctxt *sh_ctxt, struct cpu_user_regs *regs) { - struct vcpu *v = current; unsigned long addr, diff; - ASSERT(is_hvm_vcpu(v)); + ASSERT(is_hvm_vcpu(current)); /* * We don't refetch the segment bases, because we don't emulate -- git-series 0.9.1 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |