ioapic: extend definition name to avoid collision

Change EN/DISABLED to INT_EN/DISABLED to avoid collision with other
EN/DISABLE definition.

Change-Id: I85b1c544d0f31340a09e18f4b36c1942ea0fa6ef
Signed-off-by: Marc Jones <marc.jones@scarletltd.com>
Reviewed-on: https://review.coreboot.org/25540
Reviewed-by: Martin Roth <martinroth@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
Marc Jones 2018-03-31 22:45:35 -06:00 committed by Patrick Georgi
parent 4764be33e0
commit f7dc972fde
3 changed files with 7 additions and 7 deletions

View File

@ -26,8 +26,8 @@
#define ALL (0xff << 24) #define ALL (0xff << 24)
#define NONE (0) #define NONE (0)
#define DISABLED (1 << 16) #define INT_DISABLED (1 << 16)
#define ENABLED (0 << 16) #define INT_ENABLED (0 << 16)
#define TRIGGER_EDGE (0 << 15) #define TRIGGER_EDGE (0 << 15)
#define TRIGGER_LEVEL (1 << 15) #define TRIGGER_LEVEL (1 << 15)
#define POLARITY_HIGH (0 << 13) #define POLARITY_HIGH (0 << 13)

View File

@ -53,7 +53,7 @@ void clear_ioapic(void *ioapic_base)
ioapic_interrupts = ioapic_interrupt_count(ioapic_base); ioapic_interrupts = ioapic_interrupt_count(ioapic_base);
low = DISABLED; low = INT_DISABLED;
high = NONE; high = NONE;
for (i = 0; i < ioapic_interrupts; i++) { for (i = 0; i < ioapic_interrupts; i++) {
@ -118,7 +118,7 @@ static void load_vectors(void *ioapic_base)
} }
/* Enable Virtual Wire Mode. */ /* Enable Virtual Wire Mode. */
low = ENABLED | TRIGGER_EDGE | POLARITY_HIGH | PHYSICAL_DEST | ExtINT; low = INT_ENABLED | TRIGGER_EDGE | POLARITY_HIGH | PHYSICAL_DEST | ExtINT;
high = bsp_lapicid << (56 - 32); high = bsp_lapicid << (56 - 32);
io_apic_write(ioapic_base, 0x10, low); io_apic_write(ioapic_base, 0x10, low);
@ -131,7 +131,7 @@ static void load_vectors(void *ioapic_base)
printk(BIOS_SPEW, "IOAPIC: reg 0x%08x value 0x%08x 0x%08x\n", printk(BIOS_SPEW, "IOAPIC: reg 0x%08x value 0x%08x 0x%08x\n",
0, high, low); 0, high, low);
low = DISABLED; low = INT_DISABLED;
high = NONE; high = NONE;
for (i = 1; i < ioapic_interrupts; i++) { for (i = 1; i < ioapic_interrupts; i++) {
io_apic_write(ioapic_base, i * 2 + 0x10, low); io_apic_write(ioapic_base, i * 2 + 0x10, low);

View File

@ -61,7 +61,7 @@ static void ioapic_init(struct device *dev)
if (config->enable_virtual_wire) { if (config->enable_virtual_wire) {
/* Enable Virtual Wire Mode. */ /* Enable Virtual Wire Mode. */
low = ENABLED | TRIGGER_EDGE | POLARITY_HIGH | PHYSICAL_DEST | ExtINT; low = INT_ENABLED | TRIGGER_EDGE | POLARITY_HIGH | PHYSICAL_DEST | ExtINT;
high = bsp_lapicid << (56 - 32); high = bsp_lapicid << (56 - 32);
io_apic_write(ioapic_base, 0x10, low); io_apic_write(ioapic_base, 0x10, low);
@ -75,7 +75,7 @@ static void ioapic_init(struct device *dev)
printk(BIOS_SPEW, "IOAPIC: reg 0x%08x value 0x%08x 0x%08x\n", 0, printk(BIOS_SPEW, "IOAPIC: reg 0x%08x value 0x%08x 0x%08x\n", 0,
high, low); high, low);
} }
low = DISABLED; low = INT_DISABLED;
high = NONE; high = NONE;
for (i = 1; i < ioapic_interrupts; i++) { for (i = 1; i < ioapic_interrupts; i++) {