This is a note to let you know that I've just added the patch titled
tg3: Avoid null pointer dereference in tg3_interrupt in netconsole mode
to the 3.4-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
tg3-avoid-null-pointer-dereference-in-tg3_interrupt-in-netconsole-mode.patch
and it can be found in the queue-3.4 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <[email protected]> know about it.
>From 59beb7f7a982fd8d257d66ef26759236f1e47669 Mon Sep 17 00:00:00 2001
From: Nithin Nayak Sujir <[email protected]>
Date: Mon, 14 Jan 2013 17:10:59 +0000
Subject: tg3: Avoid null pointer dereference in tg3_interrupt in netconsole mode
From: Nithin Nayak Sujir <[email protected]>
[ Upstream commit 9c13cb8bb477a83b9a3c9e5a5478a4e21294a760 ]
When netconsole is enabled, logging messages generated during tg3_open
can result in a null pointer dereference for the uninitialized tg3
status block. Use the irq_sync flag to disable polling in the early
stages. irq_sync is cleared when the driver is enabling interrupts after
all initialization is completed.
Signed-off-by: Nithin Nayak Sujir <[email protected]>
Signed-off-by: Michael Chan <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
---
drivers/net/ethernet/broadcom/tg3.c | 4 ++++
1 file changed, 4 insertions(+)
--- a/drivers/net/ethernet/broadcom/tg3.c
+++ b/drivers/net/ethernet/broadcom/tg3.c
@@ -6574,6 +6574,9 @@ static void tg3_poll_controller(struct n
int i;
struct tg3 *tp = netdev_priv(dev);
+ if (tg3_irq_sync(tp))
+ return;
+
for (i = 0; i < tp->irq_cnt; i++)
tg3_interrupt(tp->napi[i].irq_vec, &tp->napi[i]);
}
@@ -15529,6 +15532,7 @@ static int __devinit tg3_init_one(struct
tp->pm_cap = pm_cap;
tp->rx_mode = TG3_DEF_RX_MODE;
tp->tx_mode = TG3_DEF_TX_MODE;
+ tp->irq_sync = 1;
if (tg3_debug > 0)
tp->msg_enable = tg3_debug;
Patches currently in stable-queue which might be from [email protected] are
queue-3.4/tg3-fix-crc-errors-on-jumbo-frame-receive.patch
queue-3.4/tg3-avoid-null-pointer-dereference-in-tg3_interrupt-in-netconsole-mode.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html