From 888dd66ea65688f2257ed01d509087fc3a97dcae Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roger=20Pau=20Monn=C3=A9?= Date: Mon, 24 Aug 2020 15:35:49 +0200 Subject: [PATCH] x86/vpic: fix vpic_elcr_mask macro parameter usage MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit vpic_elcr_mask wasn't using the v parameter, and instead worked because in the context of the callers v would be vpic. Fix this by correctly using the parameter. While there also remove the unneeded casts to uint8_t and the ending semicolon. No functional change intended. Signed-off-by: Roger Pau Monné Reviewed-by: Jan Beulich --- xen/arch/x86/hvm/vpic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xen/arch/x86/hvm/vpic.c b/xen/arch/x86/hvm/vpic.c index 61f4b6784c..936c7b27c6 100644 --- a/xen/arch/x86/hvm/vpic.c +++ b/xen/arch/x86/hvm/vpic.c @@ -41,7 +41,7 @@ #define vpic_lock(v) spin_lock(__vpic_lock(v)) #define vpic_unlock(v) spin_unlock(__vpic_lock(v)) #define vpic_is_locked(v) spin_is_locked(__vpic_lock(v)) -#define vpic_elcr_mask(v) (vpic->is_master ? (uint8_t)0xf8 : (uint8_t)0xde); +#define vpic_elcr_mask(v) ((v)->is_master ? 0xf8 : 0xde) /* Return the highest priority found in mask. Return 8 if none. */ #define VPIC_PRIO_NONE 8 -- 2.39.5