[PATCH] 2.6.8.1 modprobe tg3 oopses

From: Randy.Dunlap
Date: Sat Aug 21 2004 - 19:48:24 EST



| Subject: 2.6.8.1 "modprobe tg3" oopses with gcc 3.4.1
|
|
| I get this when trying to modprobe tg3 on an Acer Aspire 1500 notebook (32bit
| mode) when the kernel [tried 2.6.8.1 and 2.6.8.1-mm1] is compiled with gcc
| 3.4.1 (3.3.4 works):

I wouldn't expect this to be compiler-dependent. There's an obvious
problem with add_pin_to_irq(). It shouldn't be __init. Patch below.
(I thought that I had already mailed this one time, but I don't
see it anywhere.)

| CPU: 0
| EIP: 0060:[<c03ba270>] Not tainted VLI
| EFLAGS: 00210216 (2.6.8-1ark)
| EIP is at add_pin_to_irq+0x0/0x60 <<<<< code is gone

--

add_pin_to_irq() should not be __init; it is used after init code.

Signed-off-by: Randy Dunlap <rddunlap@xxxxxxxx>

diffstat:=
arch/i386/kernel/io_apic.c | 2 +-
1 files changed, 1 insertion(+), 1 deletion(-)

diff -Naurp ./arch/i386/kernel/io_apic.c~ioapic_non_init ./arch/i386/kernel/io_apic.c
--- ./arch/i386/kernel/io_apic.c~ioapic_non_init 2004-08-14 03:55:10.000000000 -0700
+++ ./arch/i386/kernel/io_apic.c 2004-08-21 17:26:52.695599728 -0700
@@ -85,7 +85,7 @@ int vector_irq[NR_VECTORS] = { [0 ... NR
* shared ISA-space IRQs, so we have to support them. We are super
* fast in the common case, and fast for shared ISA-space IRQs.
*/
-static void __init add_pin_to_irq(unsigned int irq, int apic, int pin)
+static void add_pin_to_irq(unsigned int irq, int apic, int pin)
{
static int first_free_entry = NR_IRQS;
struct irq_pin_list *entry = irq_2_pin + irq;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/