Commit f47998da authored by Thomas Gleixner's avatar Thomas Gleixner

x86/ioapic: Cleanup apic_printk()s

Replace apic_printk($LEVEL) with the corresponding apic_pr_*() helpers and
use pr_info() for APIC_QUIET as that is always printed so the indirection
is pointless noise.
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Tested-by: default avatarQiuxu Zhuo <qiuxu.zhuo@intel.com>
Tested-by: default avatarBreno Leitao <leitao@debian.org>
Link: https://lore.kernel.org/all/20240802155440.652239904@linutronix.de
parent ac1c9fc1
...@@ -201,8 +201,7 @@ void mp_save_irq(struct mpc_intsrc *m) ...@@ -201,8 +201,7 @@ void mp_save_irq(struct mpc_intsrc *m)
{ {
int i; int i;
apic_printk(APIC_VERBOSE, "Int: type %d, pol %d, trig %d, bus %02x," apic_pr_verbose("Int: type %d, pol %d, trig %d, bus %02x, IRQ %02x, APIC ID %x, APIC INT %02x\n",
" IRQ %02x, APIC ID %x, APIC INT %02x\n",
m->irqtype, m->irqflag & 3, (m->irqflag >> 2) & 3, m->srcbus, m->irqtype, m->irqflag & 3, (m->irqflag >> 2) & 3, m->srcbus,
m->srcbusirq, m->dstapic, m->dstirq); m->srcbusirq, m->dstapic, m->dstirq);
...@@ -554,28 +553,23 @@ static int pirq_entries[MAX_PIRQS] = { ...@@ -554,28 +553,23 @@ static int pirq_entries[MAX_PIRQS] = {
static int __init ioapic_pirq_setup(char *str) static int __init ioapic_pirq_setup(char *str)
{ {
int i, max; int i, max, ints[MAX_PIRQS+1];
int ints[MAX_PIRQS+1];
get_options(str, ARRAY_SIZE(ints), ints); get_options(str, ARRAY_SIZE(ints), ints);
apic_printk(APIC_VERBOSE, KERN_INFO apic_pr_verbose("PIRQ redirection, working around broken MP-BIOS.\n");
"PIRQ redirection, working around broken MP-BIOS.\n");
max = MAX_PIRQS; max = MAX_PIRQS;
if (ints[0] < MAX_PIRQS) if (ints[0] < MAX_PIRQS)
max = ints[0]; max = ints[0];
for (i = 0; i < max; i++) { for (i = 0; i < max; i++) {
apic_printk(APIC_VERBOSE, KERN_DEBUG apic_pr_verbose("... PIRQ%d -> IRQ %d\n", i, ints[i + 1]);
"... PIRQ%d -> IRQ %d\n", i, ints[i+1]); /* PIRQs are mapped upside down, usually */
/*
* PIRQs are mapped upside down, usually.
*/
pirq_entries[MAX_PIRQS-i-1] = ints[i+1]; pirq_entries[MAX_PIRQS-i-1] = ints[i+1];
} }
return 1; return 1;
} }
__setup("pirq=", ioapic_pirq_setup); __setup("pirq=", ioapic_pirq_setup);
#endif /* CONFIG_X86_32 */ #endif /* CONFIG_X86_32 */
...@@ -737,8 +731,7 @@ static bool EISA_ELCR(unsigned int irq) ...@@ -737,8 +731,7 @@ static bool EISA_ELCR(unsigned int irq)
unsigned int port = PIC_ELCR1 + (irq >> 3); unsigned int port = PIC_ELCR1 + (irq >> 3);
return (inb(port) >> (irq & 7)) & 1; return (inb(port) >> (irq & 7)) & 1;
} }
apic_printk(APIC_VERBOSE, KERN_INFO apic_pr_verbose("Broken MPtable reports ISA irq %d\n", irq);
"Broken MPtable reports ISA irq %d\n", irq);
return false; return false;
} }
...@@ -1052,15 +1045,13 @@ static int pin_2_irq(int idx, int ioapic, int pin, unsigned int flags) ...@@ -1052,15 +1045,13 @@ static int pin_2_irq(int idx, int ioapic, int pin, unsigned int flags)
* PCI IRQ command line redirection. Yes, limits are hardcoded. * PCI IRQ command line redirection. Yes, limits are hardcoded.
*/ */
if ((pin >= 16) && (pin <= 23)) { if ((pin >= 16) && (pin <= 23)) {
if (pirq_entries[pin-16] != -1) { if (pirq_entries[pin - 16] != -1) {
if (!pirq_entries[pin-16]) { if (!pirq_entries[pin - 16]) {
apic_printk(APIC_VERBOSE, KERN_DEBUG apic_pr_verbose("Disabling PIRQ%d\n", pin - 16);
"disabling PIRQ%d\n", pin-16);
} else { } else {
int irq = pirq_entries[pin-16]; int irq = pirq_entries[pin-16];
apic_printk(APIC_VERBOSE, KERN_DEBUG
"using PIRQ%d -> IRQ %d\n", apic_pr_verbose("Using PIRQ%d -> IRQ %d\n", pin - 16, irq);
pin-16, irq);
return irq; return irq;
} }
} }
...@@ -1111,12 +1102,10 @@ int IO_APIC_get_PCI_irq_vector(int bus, int slot, int pin) ...@@ -1111,12 +1102,10 @@ int IO_APIC_get_PCI_irq_vector(int bus, int slot, int pin)
{ {
int irq, i, best_ioapic = -1, best_idx = -1; int irq, i, best_ioapic = -1, best_idx = -1;
apic_printk(APIC_DEBUG, apic_pr_debug("Querying PCI -> IRQ mapping bus:%d, slot:%d, pin:%d.\n",
"querying PCI -> IRQ mapping bus:%d, slot:%d, pin:%d.\n",
bus, slot, pin); bus, slot, pin);
if (test_bit(bus, mp_bus_not_pci)) { if (test_bit(bus, mp_bus_not_pci)) {
apic_printk(APIC_VERBOSE, apic_pr_verbose("PCI BIOS passed nonexistent PCI bus %d!\n", bus);
"PCI BIOS passed nonexistent PCI bus %d!\n", bus);
return -1; return -1;
} }
...@@ -1173,17 +1162,16 @@ static void __init setup_IO_APIC_irqs(void) ...@@ -1173,17 +1162,16 @@ static void __init setup_IO_APIC_irqs(void)
unsigned int ioapic, pin; unsigned int ioapic, pin;
int idx; int idx;
apic_printk(APIC_VERBOSE, KERN_DEBUG "init IO_APIC IRQs\n"); apic_pr_verbose("Init IO_APIC IRQs\n");
for_each_ioapic_pin(ioapic, pin) { for_each_ioapic_pin(ioapic, pin) {
idx = find_irq_entry(ioapic, pin, mp_INT); idx = find_irq_entry(ioapic, pin, mp_INT);
if (idx < 0) if (idx < 0) {
apic_printk(APIC_VERBOSE, apic_pr_verbose("apic %d pin %d not connected\n",
KERN_DEBUG " apic %d pin %d not connected\n",
mpc_ioapic_id(ioapic), pin); mpc_ioapic_id(ioapic), pin);
else } else {
pin_2_irq(idx, ioapic, pin, pin_2_irq(idx, ioapic, pin, ioapic ? 0 : IOAPIC_MAP_ALLOC);
ioapic ? 0 : IOAPIC_MAP_ALLOC); }
} }
} }
...@@ -1359,29 +1347,24 @@ void __init enable_IO_APIC(void) ...@@ -1359,29 +1347,24 @@ void __init enable_IO_APIC(void)
i8259_apic = find_isa_irq_apic(0, mp_ExtINT); i8259_apic = find_isa_irq_apic(0, mp_ExtINT);
/* Trust the MP table if nothing is setup in the hardware */ /* Trust the MP table if nothing is setup in the hardware */
if ((ioapic_i8259.pin == -1) && (i8259_pin >= 0)) { if ((ioapic_i8259.pin == -1) && (i8259_pin >= 0)) {
printk(KERN_WARNING "ExtINT not setup in hardware but reported by MP table\n"); pr_warn("ExtINT not setup in hardware but reported by MP table\n");
ioapic_i8259.pin = i8259_pin; ioapic_i8259.pin = i8259_pin;
ioapic_i8259.apic = i8259_apic; ioapic_i8259.apic = i8259_apic;
} }
/* Complain if the MP table and the hardware disagree */ /* Complain if the MP table and the hardware disagree */
if (((ioapic_i8259.apic != i8259_apic) || (ioapic_i8259.pin != i8259_pin)) && if (((ioapic_i8259.apic != i8259_apic) || (ioapic_i8259.pin != i8259_pin)) &&
(i8259_pin >= 0) && (ioapic_i8259.pin >= 0)) (i8259_pin >= 0) && (ioapic_i8259.pin >= 0))
{ pr_warn("ExtINT in hardware and MP table differ\n");
printk(KERN_WARNING "ExtINT in hardware and MP table differ\n");
}
/* /* Do not trust the IO-APIC being empty at bootup */
* Do not trust the IO-APIC being empty at bootup
*/
clear_IO_APIC(); clear_IO_APIC();
} }
void native_restore_boot_irq_mode(void) void native_restore_boot_irq_mode(void)
{ {
/* /*
* If the i8259 is routed through an IOAPIC * If the i8259 is routed through an IOAPIC Put that IOAPIC in
* Put that IOAPIC in virtual wire mode * virtual wire mode so legacy interrupts can be delivered.
* so legacy interrupts can be delivered.
*/ */
if (ioapic_i8259.pin != -1) { if (ioapic_i8259.pin != -1) {
struct IO_APIC_route_entry entry; struct IO_APIC_route_entry entry;
...@@ -1469,7 +1452,7 @@ static void __init setup_ioapic_ids_from_mpc_nocheck(void) ...@@ -1469,7 +1452,7 @@ static void __init setup_ioapic_ids_from_mpc_nocheck(void)
set_bit(i, phys_id_present_map); set_bit(i, phys_id_present_map);
ioapics[ioapic_idx].mp_config.apicid = i; ioapics[ioapic_idx].mp_config.apicid = i;
} else { } else {
apic_printk(APIC_VERBOSE, "Setting %d in the phys_id_present_map\n", apic_pr_verbose("Setting %d in the phys_id_present_map\n",
mpc_ioapic_id(ioapic_idx)); mpc_ioapic_id(ioapic_idx));
set_bit(mpc_ioapic_id(ioapic_idx), phys_id_present_map); set_bit(mpc_ioapic_id(ioapic_idx), phys_id_present_map);
} }
...@@ -1491,8 +1474,7 @@ static void __init setup_ioapic_ids_from_mpc_nocheck(void) ...@@ -1491,8 +1474,7 @@ static void __init setup_ioapic_ids_from_mpc_nocheck(void)
if (mpc_ioapic_id(ioapic_idx) == reg_00.bits.ID) if (mpc_ioapic_id(ioapic_idx) == reg_00.bits.ID)
continue; continue;
apic_printk(APIC_VERBOSE, KERN_INFO apic_pr_verbose("...changing IO-APIC physical APIC ID to %d ...",
"...changing IO-APIC physical APIC ID to %d ...",
mpc_ioapic_id(ioapic_idx)); mpc_ioapic_id(ioapic_idx));
reg_00.bits.ID = mpc_ioapic_id(ioapic_idx); reg_00.bits.ID = mpc_ioapic_id(ioapic_idx);
...@@ -1504,7 +1486,7 @@ static void __init setup_ioapic_ids_from_mpc_nocheck(void) ...@@ -1504,7 +1486,7 @@ static void __init setup_ioapic_ids_from_mpc_nocheck(void)
if (reg_00.bits.ID != mpc_ioapic_id(ioapic_idx)) if (reg_00.bits.ID != mpc_ioapic_id(ioapic_idx))
pr_cont("could not set ID!\n"); pr_cont("could not set ID!\n");
else else
apic_printk(APIC_VERBOSE, " ok.\n"); apic_pr_verbose(" ok.\n");
} }
} }
...@@ -2136,8 +2118,7 @@ static inline void __init check_timer(void) ...@@ -2136,8 +2118,7 @@ static inline void __init check_timer(void)
pin2 = ioapic_i8259.pin; pin2 = ioapic_i8259.pin;
apic2 = ioapic_i8259.apic; apic2 = ioapic_i8259.apic;
apic_printk(APIC_QUIET, KERN_INFO "..TIMER: vector=0x%02X " pr_info("..TIMER: vector=0x%02X apic1=%d pin1=%d apic2=%d pin2=%d\n",
"apic1=%d pin1=%d apic2=%d pin2=%d\n",
cfg->vector, apic1, pin1, apic2, pin2); cfg->vector, apic1, pin1, apic2, pin2);
/* /*
...@@ -2182,13 +2163,10 @@ static inline void __init check_timer(void) ...@@ -2182,13 +2163,10 @@ static inline void __init check_timer(void)
panic_if_irq_remap("timer doesn't work through Interrupt-remapped IO-APIC"); panic_if_irq_remap("timer doesn't work through Interrupt-remapped IO-APIC");
clear_IO_APIC_pin(apic1, pin1); clear_IO_APIC_pin(apic1, pin1);
if (!no_pin1) if (!no_pin1)
apic_printk(APIC_QUIET, KERN_ERR "..MP-BIOS bug: " pr_err("..MP-BIOS bug: 8254 timer not connected to IO-APIC\n");
"8254 timer not connected to IO-APIC\n");
apic_printk(APIC_QUIET, KERN_INFO "...trying to set up timer " pr_info("...trying to set up timer (IRQ0) through the 8259A ...\n");
"(IRQ0) through the 8259A ...\n"); pr_info("..... (found apic %d pin %d) ...\n", apic2, pin2);
apic_printk(APIC_QUIET, KERN_INFO
"..... (found apic %d pin %d) ...\n", apic2, pin2);
/* /*
* legacy devices should be connected to IO APIC #0 * legacy devices should be connected to IO APIC #0
*/ */
...@@ -2197,7 +2175,7 @@ static inline void __init check_timer(void) ...@@ -2197,7 +2175,7 @@ static inline void __init check_timer(void)
irq_domain_activate_irq(irq_data, false); irq_domain_activate_irq(irq_data, false);
legacy_pic->unmask(0); legacy_pic->unmask(0);
if (timer_irq_works()) { if (timer_irq_works()) {
apic_printk(APIC_QUIET, KERN_INFO "....... works.\n"); pr_info("....... works.\n");
goto out; goto out;
} }
/* /*
...@@ -2205,26 +2183,24 @@ static inline void __init check_timer(void) ...@@ -2205,26 +2183,24 @@ static inline void __init check_timer(void)
*/ */
legacy_pic->mask(0); legacy_pic->mask(0);
clear_IO_APIC_pin(apic2, pin2); clear_IO_APIC_pin(apic2, pin2);
apic_printk(APIC_QUIET, KERN_INFO "....... failed.\n"); pr_info("....... failed.\n");
} }
apic_printk(APIC_QUIET, KERN_INFO pr_info("...trying to set up timer as Virtual Wire IRQ...\n");
"...trying to set up timer as Virtual Wire IRQ...\n");
lapic_register_intr(0); lapic_register_intr(0);
apic_write(APIC_LVT0, APIC_DM_FIXED | cfg->vector); /* Fixed mode */ apic_write(APIC_LVT0, APIC_DM_FIXED | cfg->vector); /* Fixed mode */
legacy_pic->unmask(0); legacy_pic->unmask(0);
if (timer_irq_works()) { if (timer_irq_works()) {
apic_printk(APIC_QUIET, KERN_INFO "..... works.\n"); pr_info("..... works.\n");
goto out; goto out;
} }
legacy_pic->mask(0); legacy_pic->mask(0);
apic_write(APIC_LVT0, APIC_LVT_MASKED | APIC_DM_FIXED | cfg->vector); apic_write(APIC_LVT0, APIC_LVT_MASKED | APIC_DM_FIXED | cfg->vector);
apic_printk(APIC_QUIET, KERN_INFO "..... failed.\n"); pr_info("..... failed.\n");
apic_printk(APIC_QUIET, KERN_INFO pr_info("...trying to set up timer as ExtINT IRQ...\n");
"...trying to set up timer as ExtINT IRQ...\n");
legacy_pic->init(0); legacy_pic->init(0);
legacy_pic->make_irq(0); legacy_pic->make_irq(0);
...@@ -2234,14 +2210,15 @@ static inline void __init check_timer(void) ...@@ -2234,14 +2210,15 @@ static inline void __init check_timer(void)
unlock_ExtINT_logic(); unlock_ExtINT_logic();
if (timer_irq_works()) { if (timer_irq_works()) {
apic_printk(APIC_QUIET, KERN_INFO "..... works.\n"); pr_info("..... works.\n");
goto out; goto out;
} }
apic_printk(APIC_QUIET, KERN_INFO "..... failed :(.\n");
if (apic_is_x2apic_enabled()) pr_info("..... failed :\n");
apic_printk(APIC_QUIET, KERN_INFO if (apic_is_x2apic_enabled()) {
"Perhaps problem with the pre-enabled x2apic mode\n" pr_info("Perhaps problem with the pre-enabled x2apic mode\n"
"Try booting with x2apic and interrupt-remapping disabled in the bios.\n"); "Try booting with x2apic and interrupt-remapping disabled in the bios.\n");
}
panic("IO-APIC + timer doesn't work! Boot with apic=debug and send a " panic("IO-APIC + timer doesn't work! Boot with apic=debug and send a "
"report. Then try booting with the 'noapic' option.\n"); "report. Then try booting with the 'noapic' option.\n");
out: out:
...@@ -2339,7 +2316,7 @@ void __init setup_IO_APIC(void) ...@@ -2339,7 +2316,7 @@ void __init setup_IO_APIC(void)
io_apic_irqs = nr_legacy_irqs() ? ~PIC_IRQS : ~0UL; io_apic_irqs = nr_legacy_irqs() ? ~PIC_IRQS : ~0UL;
apic_printk(APIC_VERBOSE, "ENABLING IO-APIC IRQs\n"); apic_pr_verbose("ENABLING IO-APIC IRQs\n");
for_each_ioapic(ioapic) for_each_ioapic(ioapic)
BUG_ON(mp_irqdomain_create(ioapic)); BUG_ON(mp_irqdomain_create(ioapic));
...@@ -2478,7 +2455,7 @@ static int io_apic_get_unique_id(int ioapic, int apic_id) ...@@ -2478,7 +2455,7 @@ static int io_apic_get_unique_id(int ioapic, int apic_id)
} }
} }
apic_printk(APIC_VERBOSE, KERN_INFO "IOAPIC[%d]: Assigned apic_id %d\n", ioapic, apic_id); apic_pr_verbose("IOAPIC[%d]: Assigned apic_id %d\n", ioapic, apic_id);
return apic_id; return apic_id;
} }
...@@ -2514,7 +2491,7 @@ static u8 io_apic_unique_id(int idx, u8 id) ...@@ -2514,7 +2491,7 @@ static u8 io_apic_unique_id(int idx, u8 id)
new_id = reg_00.bits.ID; new_id = reg_00.bits.ID;
if (!test_bit(new_id, used)) { if (!test_bit(new_id, used)) {
apic_printk(APIC_VERBOSE, KERN_INFO "IOAPIC[%d]: Using reg apic_id %d instead of %d\n", apic_pr_verbose("IOAPIC[%d]: Using reg apic_id %d instead of %d\n",
idx, new_id, id); idx, new_id, id);
return new_id; return new_id;
} }
...@@ -2614,9 +2591,7 @@ void __init io_apic_init_mappings(void) ...@@ -2614,9 +2591,7 @@ void __init io_apic_init_mappings(void)
ioapic_phys = mpc_ioapic_addr(i); ioapic_phys = mpc_ioapic_addr(i);
#ifdef CONFIG_X86_32 #ifdef CONFIG_X86_32
if (!ioapic_phys) { if (!ioapic_phys) {
printk(KERN_ERR pr_err("WARNING: bogus zero IO-APIC address found in MPTABLE, "
"WARNING: bogus zero IO-APIC "
"address found in MPTABLE, "
"disabling IO/APIC support!\n"); "disabling IO/APIC support!\n");
smp_found_config = 0; smp_found_config = 0;
ioapic_is_disabled = true; ioapic_is_disabled = true;
...@@ -2635,9 +2610,8 @@ void __init io_apic_init_mappings(void) ...@@ -2635,9 +2610,8 @@ void __init io_apic_init_mappings(void)
ioapic_phys = __pa(ioapic_phys); ioapic_phys = __pa(ioapic_phys);
} }
io_apic_set_fixmap(idx, ioapic_phys); io_apic_set_fixmap(idx, ioapic_phys);
apic_printk(APIC_VERBOSE, "mapped IOAPIC to %08lx (%08lx)\n", apic_pr_verbose("mapped IOAPIC to %08lx (%08lx)\n",
__fix_to_virt(idx) + (ioapic_phys & ~PAGE_MASK), __fix_to_virt(idx) + (ioapic_phys & ~PAGE_MASK), ioapic_phys);
ioapic_phys);
idx++; idx++;
ioapic_res->start = ioapic_phys; ioapic_res->start = ioapic_phys;
...@@ -2648,13 +2622,12 @@ void __init io_apic_init_mappings(void) ...@@ -2648,13 +2622,12 @@ void __init io_apic_init_mappings(void)
void __init ioapic_insert_resources(void) void __init ioapic_insert_resources(void)
{ {
int i;
struct resource *r = ioapic_resources; struct resource *r = ioapic_resources;
int i;
if (!r) { if (!r) {
if (nr_ioapics > 0) if (nr_ioapics > 0)
printk(KERN_ERR pr_err("IO APIC resources couldn't be allocated.\n");
"IO APIC resources couldn't be allocated.\n");
return; return;
} }
...@@ -2674,11 +2647,12 @@ int mp_find_ioapic(u32 gsi) ...@@ -2674,11 +2647,12 @@ int mp_find_ioapic(u32 gsi)
/* Find the IOAPIC that manages this GSI. */ /* Find the IOAPIC that manages this GSI. */
for_each_ioapic(i) { for_each_ioapic(i) {
struct mp_ioapic_gsi *gsi_cfg = mp_ioapic_gsi_routing(i); struct mp_ioapic_gsi *gsi_cfg = mp_ioapic_gsi_routing(i);
if (gsi >= gsi_cfg->gsi_base && gsi <= gsi_cfg->gsi_end) if (gsi >= gsi_cfg->gsi_base && gsi <= gsi_cfg->gsi_end)
return i; return i;
} }
printk(KERN_ERR "ERROR: Unable to locate IOAPIC for GSI %d\n", gsi); pr_err("ERROR: Unable to locate IOAPIC for GSI %d\n", gsi);
return -1; return -1;
} }
...@@ -2745,12 +2719,13 @@ int mp_register_ioapic(int id, u32 address, u32 gsi_base, ...@@ -2745,12 +2719,13 @@ int mp_register_ioapic(int id, u32 address, u32 gsi_base,
pr_warn("Bogus (zero) I/O APIC address found, skipping!\n"); pr_warn("Bogus (zero) I/O APIC address found, skipping!\n");
return -EINVAL; return -EINVAL;
} }
for_each_ioapic(ioapic)
for_each_ioapic(ioapic) {
if (ioapics[ioapic].mp_config.apicaddr == address) { if (ioapics[ioapic].mp_config.apicaddr == address) {
pr_warn("address 0x%x conflicts with IOAPIC%d\n", pr_warn("address 0x%x conflicts with IOAPIC%d\n", address, ioapic);
address, ioapic);
return -EEXIST; return -EEXIST;
} }
}
idx = find_free_ioapic_entry(); idx = find_free_ioapic_entry();
if (idx >= MAX_IO_APICS) { if (idx >= MAX_IO_APICS) {
...@@ -2785,8 +2760,7 @@ int mp_register_ioapic(int id, u32 address, u32 gsi_base, ...@@ -2785,8 +2760,7 @@ int mp_register_ioapic(int id, u32 address, u32 gsi_base,
(gsi_end >= gsi_cfg->gsi_base && (gsi_end >= gsi_cfg->gsi_base &&
gsi_end <= gsi_cfg->gsi_end)) { gsi_end <= gsi_cfg->gsi_end)) {
pr_warn("GSI range [%u-%u] for new IOAPIC conflicts with GSI[%u-%u]\n", pr_warn("GSI range [%u-%u] for new IOAPIC conflicts with GSI[%u-%u]\n",
gsi_base, gsi_end, gsi_base, gsi_end, gsi_cfg->gsi_base, gsi_cfg->gsi_end);
gsi_cfg->gsi_base, gsi_cfg->gsi_end);
clear_fixmap(FIX_IO_APIC_BASE_0 + idx); clear_fixmap(FIX_IO_APIC_BASE_0 + idx);
return -ENOSPC; return -ENOSPC;
} }
...@@ -2820,8 +2794,7 @@ int mp_register_ioapic(int id, u32 address, u32 gsi_base, ...@@ -2820,8 +2794,7 @@ int mp_register_ioapic(int id, u32 address, u32 gsi_base,
ioapics[idx].nr_registers = entries; ioapics[idx].nr_registers = entries;
pr_info("IOAPIC[%d]: apic_id %d, version %d, address 0x%x, GSI %d-%d\n", pr_info("IOAPIC[%d]: apic_id %d, version %d, address 0x%x, GSI %d-%d\n",
idx, mpc_ioapic_id(idx), idx, mpc_ioapic_id(idx), mpc_ioapic_ver(idx), mpc_ioapic_addr(idx),
mpc_ioapic_ver(idx), mpc_ioapic_addr(idx),
gsi_cfg->gsi_base, gsi_cfg->gsi_end); gsi_cfg->gsi_base, gsi_cfg->gsi_end);
return 0; return 0;
...@@ -2850,8 +2823,7 @@ int mp_unregister_ioapic(u32 gsi_base) ...@@ -2850,8 +2823,7 @@ int mp_unregister_ioapic(u32 gsi_base)
if (irq >= 0) { if (irq >= 0) {
data = irq_get_chip_data(irq); data = irq_get_chip_data(irq);
if (data && data->count) { if (data && data->count) {
pr_warn("pin%d on IOAPIC%d is still in use.\n", pr_warn("pin%d on IOAPIC%d is still in use.\n", pin, ioapic);
pin, ioapic);
return -EBUSY; return -EBUSY;
} }
} }
...@@ -2968,10 +2940,8 @@ int mp_irqdomain_alloc(struct irq_domain *domain, unsigned int virq, ...@@ -2968,10 +2940,8 @@ int mp_irqdomain_alloc(struct irq_domain *domain, unsigned int virq,
legacy_pic->mask(virq); legacy_pic->mask(virq);
local_irq_restore(flags); local_irq_restore(flags);
apic_printk(APIC_VERBOSE, KERN_DEBUG apic_pr_verbose("IOAPIC[%d]: Preconfigured routing entry (%d-%d -> IRQ %d Level:%i ActiveLow:%i)\n",
"IOAPIC[%d]: Preconfigured routing entry (%d-%d -> IRQ %d Level:%i ActiveLow:%i)\n", ioapic, mpc_ioapic_id(ioapic), pin, virq, data->is_level, data->active_low);
ioapic, mpc_ioapic_id(ioapic), pin, virq,
data->is_level, data->active_low);
return 0; return 0;
free_irqs: free_irqs:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment