From: Gary Zambrano Date: Sat, 5 May 2007 18:51:45 +0000 (-0700) Subject: [TG3]: Clear GPIO mask before storing. X-Git-Tag: v2.6.22-rc1~1014^2~5 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=aaf84465fc994e9a840a8c0c6fa842b54cdb3426;p=linux-2.6 [TG3]: Clear GPIO mask before storing. The GPIO settings may change during reset and so the stored values in tp->grc_local_ctrl should be cleared first. Signed-off-by: Gary Zambrano Signed-off-by: Michael Chan Signed-off-by: David S. Miller --- diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c index c01bd861ac..00027a14ea 100644 --- a/drivers/net/tg3.c +++ b/drivers/net/tg3.c @@ -6454,6 +6454,7 @@ static int tg3_reset_hw(struct tg3 *tp, int reset_phy) if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755) gpio_mask |= GRC_LCLCTRL_GPIO_UART_SEL; + tp->grc_local_ctrl &= ~gpio_mask; tp->grc_local_ctrl |= tr32(GRC_LOCAL_CTRL) & gpio_mask; /* GPIO1 must be driven high for eeprom write protect */