From: "Michael Chan" <[EMAIL PROTECTED]>
Date: Tue, 13 Dec 2005 14:19:40 -0800

> Yes, your patch looks cleaner but will require additional changes.
> Sometimes, we get the lock just before chip reset and we don't release
> it because the reset automatically releases it. We'll have to reset the
> lock_cnt in that case.

Like this?

diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c
index be1f30a..eadc0c3 100644
--- a/drivers/net/tg3.c
+++ b/drivers/net/tg3.c
@@ -4368,6 +4368,9 @@ static int tg3_chip_reset(struct tg3 *tp
 
        udelay(120);
 
+       /* The chip reset undoes the nvram lock done above.  */
+       tp->nvram_lock_cnt = 0;
+
        if (tp->tg3_flags2 & TG3_FLG2_PCI_EXPRESS) {
                if (tp->pci_chip_rev_id == CHIPREV_ID_5750_A0) {
                        int i;
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to