Skip to content

Commit

Permalink
x86: fix IO APIC resource allocation error message
Browse files Browse the repository at this point in the history
Impact: fix incorrect error message

- IO APIC resource allocation error message contains one too many "be".

- Print the error message iff there are IO APICs in the system.

I've seen this error message for some time on my x86-32 laptop...

Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Cc: Alan Bartlett <ajb.stxsl@googlemail.com>
LKML-Reference: <200903202100.30789.bzolnier@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
  • Loading branch information
Bartlomiej Zolnierkiewicz authored and Ingo Molnar committed Mar 20, 2009
1 parent 7f00a24 commit 04c93ce
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions arch/x86/kernel/apic/io_apic.c
Original file line number Diff line number Diff line change
Expand Up @@ -4130,9 +4130,12 @@ static int __init ioapic_insert_resources(void)
struct resource *r = ioapic_resources;

if (!r) {
printk(KERN_ERR
"IO APIC resources could be not be allocated.\n");
return -1;
if (nr_ioapics > 0) {
printk(KERN_ERR
"IO APIC resources couldn't be allocated.\n");
return -1;
}
return 0;
}

for (i = 0; i < nr_ioapics; i++) {
Expand Down

0 comments on commit 04c93ce

Please sign in to comment.