blob: 021d0d2d97f37c2940f4ef939a0c25827e801916 [file] [log] [blame]
Ben Hutchings8ceee662008-04-27 12:55:59 +01001/****************************************************************************
2 * Driver for Solarflare Solarstorm network controllers and boards
3 * Copyright 2006-2008 Solarflare Communications Inc.
4 *
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 */
9
10#ifndef EFX_WORKAROUNDS_H
11#define EFX_WORKAROUNDS_H
12
13/*
14 * Hardware workarounds.
15 * Bug numbers are from Solarflare's Bugzilla.
16 */
17
18#define EFX_WORKAROUND_ALWAYS(efx) 1
Ben Hutchingsdaeda632009-11-28 05:36:04 +000019#define EFX_WORKAROUND_FALCON_A(efx) (efx_nic_rev(efx) <= EFX_REV_FALCON_A1)
20#define EFX_WORKAROUND_FALCON_AB(efx) (efx_nic_rev(efx) <= EFX_REV_FALCON_B0)
Ben Hutchings6f158d52008-12-12 22:00:49 -080021#define EFX_WORKAROUND_10G(efx) EFX_IS10G(efx)
Steve Hodgson8b9dc8d2009-01-29 17:49:09 +000022#define EFX_WORKAROUND_SFT9001(efx) ((efx)->phy_type == PHY_TYPE_SFT9001A || \
23 (efx)->phy_type == PHY_TYPE_SFT9001B)
Ben Hutchings8ceee662008-04-27 12:55:59 +010024
25/* XAUI resets if link not detected */
26#define EFX_WORKAROUND_5147 EFX_WORKAROUND_ALWAYS
Ben Hutchings8ceee662008-04-27 12:55:59 +010027/* RX PCIe double split performance issue */
28#define EFX_WORKAROUND_7575 EFX_WORKAROUND_ALWAYS
Ben Hutchings3e133c42008-11-04 20:34:56 +000029/* Bit-bashed I2C reads cause performance drop */
Ben Hutchings6f158d52008-12-12 22:00:49 -080030#define EFX_WORKAROUND_7884 EFX_WORKAROUND_10G
Ben Hutchings8ceee662008-04-27 12:55:59 +010031/* TX_EV_PKT_ERR can be caused by a dangling TX descriptor
32 * or a PCIe error (bug 11028) */
33#define EFX_WORKAROUND_10727 EFX_WORKAROUND_ALWAYS
34/* Transmit flow control may get disabled */
Ben Hutchingsfb45f2c2009-11-28 05:35:09 +000035#define EFX_WORKAROUND_11482 EFX_WORKAROUND_FALCON_AB
Ben Hutchingsbb145a92009-03-20 13:25:39 +000036/* Truncated IPv4 packets can confuse the TX packet parser */
Ben Hutchingsfb45f2c2009-11-28 05:35:09 +000037#define EFX_WORKAROUND_15592 EFX_WORKAROUND_FALCON_AB
Ben Hutchings8ceee662008-04-27 12:55:59 +010038
39/* Spurious parity errors in TSORT buffers */
40#define EFX_WORKAROUND_5129 EFX_WORKAROUND_FALCON_A
Ben Hutchings63f19882009-10-23 08:31:20 +000041/* Unaligned read request >512 bytes after aligning may break TSORT */
42#define EFX_WORKAROUND_5391 EFX_WORKAROUND_FALCON_A
Ben Hutchings8ceee662008-04-27 12:55:59 +010043/* 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
55
Ben Hutchingse6fa2eb2008-12-12 22:00:17 -080056/* Need to send XNP pages for 100BaseT */
Ben Hutchingsc9d5a532009-01-29 17:52:11 +000057#define EFX_WORKAROUND_13204 EFX_WORKAROUND_SFT9001
Steve Hodgson8b9dc8d2009-01-29 17:49:09 +000058/* Don't restart AN in near-side loopback */
59#define EFX_WORKAROUND_15195 EFX_WORKAROUND_SFT9001
60
Ben Hutchings8ceee662008-04-27 12:55:59 +010061#endif /* EFX_WORKAROUNDS_H */