sky2: turn of dynamic Tx watermark workaround (FE+ only)
authorStephen Hemminger <shemminger@linux-foundation.org>
Tue, 27 Nov 2007 19:02:07 +0000 (11:02 -0800)
committerJeff Garzik <jeff@garzik.org>
Sat, 1 Dec 2007 21:32:31 +0000 (16:32 -0500)
Add workaround for issues FE+ (A0) transmit watermark.
This is copied verbatim from vendor driver sk98lin (10.22.4.3).
Don't have that chip version and no more information seems to be available.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
drivers/net/sky2.c

index a42f1c7ac18f75b0a40d74159fc1f478743c8d73..3d1dfc9484057a19ea2de3062a6823440d6009d1 100644 (file)
@@ -845,6 +845,13 @@ static void sky2_mac_init(struct sky2_hw *hw, unsigned port)
                sky2_set_tx_stfwd(hw, port);
        }
 
+       if (hw->chip_id == CHIP_ID_YUKON_FE_P &&
+           hw->chip_rev == CHIP_REV_YU_FE2_A0) {
+               /* disable dynamic watermark */
+               reg = sky2_read16(hw, SK_REG(port, TX_GMF_EA));
+               reg &= ~TX_DYN_WM_ENA;
+               sky2_write16(hw, SK_REG(port, TX_GMF_EA), reg);
+       }
 }
 
 /* Assign Ram Buffer allocation to queue */