sfc: SFT9001: Fix speed reporting in 1G PHY loopback
[linux-2.6/mini2440.git] / drivers / net / sfc / workarounds.h
blob420fe153ea2f1641b23ce84fbd8999794483513b
1 /****************************************************************************
2 * Driver for Solarflare Solarstorm network controllers and boards
3 * Copyright 2006-2008 Solarflare Communications Inc.
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 as published
7 * by the Free Software Foundation, incorporated herein by reference.
8 */
10 #ifndef EFX_WORKAROUNDS_H
11 #define EFX_WORKAROUNDS_H
14 * Hardware workarounds.
15 * Bug numbers are from Solarflare's Bugzilla.
18 #define EFX_WORKAROUND_ALWAYS(efx) 1
19 #define EFX_WORKAROUND_FALCON_A(efx) (falcon_rev(efx) <= FALCON_REV_A1)
20 #define EFX_WORKAROUND_10G(efx) EFX_IS10G(efx)
21 #define EFX_WORKAROUND_SFT9001A(efx) ((efx)->phy_type == PHY_TYPE_SFT9001A)
22 #define EFX_WORKAROUND_SFT9001(efx) ((efx)->phy_type == PHY_TYPE_SFT9001A || \
23 (efx)->phy_type == PHY_TYPE_SFT9001B)
25 /* XAUI resets if link not detected */
26 #define EFX_WORKAROUND_5147 EFX_WORKAROUND_ALWAYS
27 /* RX PCIe double split performance issue */
28 #define EFX_WORKAROUND_7575 EFX_WORKAROUND_ALWAYS
29 /* Bit-bashed I2C reads cause performance drop */
30 #define EFX_WORKAROUND_7884 EFX_WORKAROUND_10G
31 /* TX pkt parser problem with <= 16 byte TXes */
32 #define EFX_WORKAROUND_9141 EFX_WORKAROUND_ALWAYS
33 /* TX_EV_PKT_ERR can be caused by a dangling TX descriptor
34 * or a PCIe error (bug 11028) */
35 #define EFX_WORKAROUND_10727 EFX_WORKAROUND_ALWAYS
36 /* Transmit flow control may get disabled */
37 #define EFX_WORKAROUND_11482 EFX_WORKAROUND_ALWAYS
38 /* Flush events can take a very long time to appear */
39 #define EFX_WORKAROUND_11557 EFX_WORKAROUND_ALWAYS
41 /* Spurious parity errors in TSORT buffers */
42 #define EFX_WORKAROUND_5129 EFX_WORKAROUND_FALCON_A
43 /* iSCSI parsing errors */
44 #define EFX_WORKAROUND_5583 EFX_WORKAROUND_FALCON_A
45 /* RX events go missing */
46 #define EFX_WORKAROUND_5676 EFX_WORKAROUND_FALCON_A
47 /* RX_RESET on A1 */
48 #define EFX_WORKAROUND_6555 EFX_WORKAROUND_FALCON_A
49 /* Increase filter depth to avoid RX_RESET */
50 #define EFX_WORKAROUND_7244 EFX_WORKAROUND_FALCON_A
51 /* Flushes may never complete */
52 #define EFX_WORKAROUND_7803 EFX_WORKAROUND_FALCON_A
53 /* Leak overlength packets rather than free */
54 #define EFX_WORKAROUND_8071 EFX_WORKAROUND_FALCON_A
56 /* Need to send XNP pages for 100BaseT */
57 #define EFX_WORKAROUND_13204 EFX_WORKAROUND_SFT9001A
58 /* Need to keep AN enabled */
59 #define EFX_WORKAROUND_13963 EFX_WORKAROUND_SFT9001A
61 /* Don't restart AN in near-side loopback */
62 #define EFX_WORKAROUND_15195 EFX_WORKAROUND_SFT9001
64 #endif /* EFX_WORKAROUNDS_H */