From 96f8d6325a69fbd4a5cde529dc1c3d5eae3a960a Mon Sep 17 00:00:00 2001 From: Pavel Butsykin Date: Fri, 16 Feb 2018 00:17:51 -0500 Subject: [PATCH] apic_internal.h: fix formatting and drop unused consts Fix formatting of local apic definitions and drop unused constant APIC_INPUT_POLARITY, APIC_SEND_PENDING. Magic numbers in shifts are replaced with constants defined just above. Backports commit b6cfc3c2ac5a1025d8fe7d74421a73ec495408f9 from qemu --- qemu/include/hw/i386/apic_internal.h | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/qemu/include/hw/i386/apic_internal.h b/qemu/include/hw/i386/apic_internal.h index 0a03cb66..b528514d 100644 --- a/qemu/include/hw/i386/apic_internal.h +++ b/qemu/include/hw/i386/apic_internal.h @@ -62,12 +62,10 @@ #define APIC_LVT_DELIV_MOD_SHIFT 8 #define APIC_LVT_TIMER_TSCDEADLINE (2 << APIC_LVT_TIMER_SHIFT) -#define APIC_LVT_TIMER_PERIODIC (1<<17) -#define APIC_LVT_MASKED (1<<16) -#define APIC_LVT_LEVEL_TRIGGER (1<<15) -#define APIC_LVT_REMOTE_IRR (1<<14) -#define APIC_INPUT_POLARITY (1<<13) -#define APIC_SEND_PENDING (1<<12) +#define APIC_LVT_TIMER_PERIODIC (1 << APIC_LVT_TIMER_SHIFT) +#define APIC_LVT_MASKED (1 << APIC_LVT_MASKED_SHIFT) +#define APIC_LVT_LEVEL_TRIGGER (1 << APIC_LVT_LEVEL_TRIGGER_SHIFT) +#define APIC_LVT_REMOTE_IRR (1 << APIC_LVT_REMOTE_IRR_SHIFT) #define APIC_LVT_INT_POLARITY (1 << APIC_LVT_INT_POLARITY_SHIFT) #define APIC_LVT_DELIV_STS (1 << APIC_LVT_DELIV_STS_SHIFT) #define APIC_LVT_DELIV_MOD (7 << APIC_LVT_DELIV_MOD_SHIFT)