From: Stephen Hemminger <shemminger@linux-foundation.org>
To: Jeff Garzik <jgarzik@pobox.com>
Cc: netdev@vger.kernel.org
Cc: Greg KH <greg@kroah.com>
Subject: [PATCH 15/17] sky2: only disable 88e8056 on some boards
Date: Tue, 08 May 2007 20:50:04 -0700 [thread overview]
Message-ID: <20070509035030.939143538@linux-foundation.org> (raw)
In-Reply-To: 20070509034949.624934448@linux-foundation.org
[-- Attachment #1: sky2-dmi-gigabyte.patch --]
[-- Type: text/plain, Size: 2885 bytes --]
Use DMI to add a blacklist of broken board. For now only one is known
bad. Gentoo users report driver works on other motherboards (strange).
Hopefully, the problems will be solved later, and the the whole
blacklist can disappear.
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
---
drivers/net/sky2.c | 41 ++++++++++++++++++++++++++++++-----------
1 file changed, 30 insertions(+), 11 deletions(-)
--- sky2-2.6.21.orig/drivers/net/sky2.c 2007-05-08 15:58:11.000000000 -0700
+++ sky2-2.6.21/drivers/net/sky2.c 2007-05-08 16:09:03.000000000 -0700
@@ -41,6 +41,7 @@
#include <linux/if_vlan.h>
#include <linux/prefetch.h>
#include <linux/mii.h>
+#include <linux/dmi.h>
#include <asm/irq.h>
@@ -151,6 +152,8 @@ static const char *yukon2_name[] = {
"FE", /* 0xb7 */
};
+static int broken_ec_u; /* blacklist */
+
/* Access to external PHY */
static int gm_phy_write(struct sky2_hw *hw, unsigned port, u16 reg, u16 val)
{
@@ -2519,10 +2522,21 @@ static int __devinit sky2_init(struct sk
return -EOPNOTSUPP;
}
+
if (hw->chip_id == CHIP_ID_YUKON_EX)
dev_warn(&hw->pdev->dev, "this driver not yet tested on this chip type\n"
"Please report success or failure to <netdev@vger.kernel.org>\n");
+
+ /* Some Gigabyte motherboards have 88e8056 but cause problems
+ * There is some unresolved hardware related problem that causes
+ * descriptor errors and receive data corruption.
+ */
+ if (hw->chip_id == CHIP_ID_YUKON_EC_U && broken_ec_u) {
+ dev_err(&hw->pdev->dev, "broken 88e8056 detected.\n");
+ return -EOPNOTSUPP;
+ }
+
/* Make sure and enable all clocks */
if (hw->chip_id == CHIP_ID_YUKON_EX || hw->chip_id == CHIP_ID_YUKON_EC_U)
pci_write_config_dword(hw->pdev, PCI_DEV_REG3, 0);
@@ -3572,17 +3586,6 @@ static int __devinit sky2_probe(struct p
goto err_out;
}
- /* Some Gigabyte motherboards have 88e8056 but cause problems
- * There is some unresolved hardware related problem that causes
- * descriptor errors and receive data corruption.
- */
- if (pdev->vendor == PCI_VENDOR_ID_MARVELL &&
- pdev->device == 0x4364 && pdev->subsystem_vendor == 0x1458) {
- dev_err(&pdev->dev,
- "88E8056 on Gigabyte motherboards not supported\n");
- goto err_out_disable;
- }
-
err = pci_request_regions(pdev, DRV_NAME);
if (err) {
dev_err(&pdev->dev, "cannot obtain PCI resources\n");
@@ -3895,8 +3898,24 @@ static struct pci_driver sky2_driver = {
.shutdown = sky2_shutdown,
};
+
+static struct dmi_system_id __initdata gigabyte_dmi_table[] = {
+ {
+ .ident = "Gigabyte 965P-S3",
+ .matches = {
+ DMI_MATCH(DMI_SYS_VENDOR, "Gigabyte Technology Co., Ltd."),
+ DMI_MATCH(DMI_PRODUCT_NAME, "965P-S3"),
+
+ },
+ },
+ { }
+};
+
static int __init sky2_init_module(void)
{
+ if (dmi_check_system(gigabyte_dmi_table))
+ broken_ec_u = 1;
+
return pci_register_driver(&sky2_driver);
}
--
next prev parent reply other threads:[~2007-05-09 4:09 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-09 3:49 [PATCH 00/17] sky2 update for 2.6.22 Stephen Hemminger
2007-05-09 3:49 ` [PATCH 01/17] sky2: fix oops on shutdown Stephen Hemminger
2007-05-09 3:49 ` [PATCH 02/17] sky2: dont restrict config space access Stephen Hemminger
2007-05-09 3:49 ` [PATCH 03/17] sky2: keep track of receive alloc failures Stephen Hemminger
2007-05-09 3:49 ` [PATCH 04/17] sky2: remove dual port workaround Stephen Hemminger
2007-05-09 3:49 ` [PATCH 05/17] pci: advanced error reporting stub return values Stephen Hemminger
2007-05-10 15:48 ` Stephen Hemminger
2007-05-09 3:49 ` [PATCH 06/17] sky2: advanced error reporting Stephen Hemminger
2007-05-09 17:05 ` Linas Vepstas
2007-05-09 22:35 ` Stephen Hemminger
2007-05-09 3:49 ` [PATCH 07/17] sky2: use pci_config access functions Stephen Hemminger
2007-05-09 3:49 ` [PATCH 08/17] sky2: MIB counter overflow handling Stephen Hemminger
2007-05-09 3:49 ` [PATCH 09/17] sky2: memory barriers change Stephen Hemminger
2007-05-09 3:49 ` [PATCH 10/17] sky2: add prefetch for next skb on receive Stephen Hemminger
2007-05-09 3:50 ` [PATCH 11/17] sky2: use MII defines Stephen Hemminger
2007-05-09 3:50 ` [PATCH 12/17] sky2: chip id enum Stephen Hemminger
2007-05-09 3:50 ` [PATCH 13/17] sky2: whitespace cleanups Stephen Hemminger
2007-05-09 3:50 ` [PATCH 14/17] pci_wake_enabled function Stephen Hemminger
2007-05-09 3:50 ` Stephen Hemminger [this message]
2007-05-09 3:50 ` [PATCH 16/17] sky2: make sure high DMA bits set Stephen Hemminger
2007-05-09 3:50 ` [PATCH 17/17] sky2: version 1.15 Stephen Hemminger
2007-05-09 4:16 ` [PATCH 00/17] sky2 update for 2.6.22 Jeff Garzik
2007-05-09 14:48 ` Stephen Hemminger
2007-05-09 23:27 ` Jeff Garzik
2007-05-10 5:08 ` Stephen Hemminger
-- strict thread matches above, loose matches on Subject: below --
2007-05-14 4:53 [PATCH 15/17] sky2: only disable 88e8056 on some boards Florin Malita
2007-05-14 19:55 ` Stephen Hemminger
2007-05-15 19:43 ` kernel
2007-05-15 21:41 ` Stephen Hemminger
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070509035030.939143538@linux-foundation.org \
--to=shemminger@linux-foundation.org \
--cc=jgarzik@pobox.com \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).