Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 05 Jan 2003 11:51:04 -0800
From:      walt <wsheets@sbcglobal.net>
To:        jdp@freebsd.org, freebsd-stable@freebsd.org
Subject:   Asus A7V8X mobo with bge (again)
Message-ID:  <3E188CA8.5000900@sbcglobal.net>

next in thread | raw e-mail | index | archive | help
I see there were several posts about this back in October concerning
kernel panics.

I have the same mobo but the problem is not as bad as it was then.

The Broadcom chip is recognized but when given this command:
'ifconfig media 100baseTX'
it returns a 'device not configured' error message.

George Cox posted this patch to the -CURRENT mailing list on Jan 1
which fixes the problem for me.  Could someone review this and
consider committing it or some variation of it?

--- if_bge.c.orig	Tue Dec 31 01:21:41 2002
+++ if_bge.c	Wed Jan  1 04:51:08 2003
@@ -1519,7 +1519,7 @@
  	u_int32_t command;
  	struct ifnet *ifp;
  	struct bge_softc *sc;
-	u_int32_t hwcfg = 0;
+	u_int32_t hwcfg = 0, pcissid = 0;
  	u_int32_t mac_addr = 0;
  	int unit, error = 0, rid;

@@ -1701,9 +1701,19 @@
  	if ((ntohl(hwcfg) & BGE_HWCFG_MEDIA) == BGE_MEDIA_FIBER)
  		sc->bge_tbi = 1;

-	/* The SysKonnect SK-9D41 is a 1000baseSX card. */
-	if ((pci_read_config(dev, BGE_PCI_SUBSYS, 4) >> 16) == SK_SUBSYSID_9D41)
-		sc->bge_tbi = 1;
+	/* check for 1000baseSX cards detectable via their PCI subsystem IDs */
+	pcissid = (pci_read_config(dev, BGE_PCI_SUBSYS, 4) >> 16);
+	printf("bge%d: PCI subsystem ID is 0x%08x\n", sc->bge_unit, pcissid);
+
+	switch (pcissid) {
+		case SK_SUBSYSID_9D41:
+		case BCOM_SUBSYSID_UNKNOWN_0x0124:
+		case BCOM_SUBSYSID_UNKNOWN_0x0126:
+		case BCOM_SUBSYSID_UNKNOWN_0x1646:
+			printf("bge%d: 1000baseSX capable; enabling TBI\n", sc->bge_unit);
+			sc->bge_tbi = 1;
+		default:
+	}

  	if (sc->bge_tbi) {
  		ifmedia_init(&sc->bge_ifmedia, IFM_IMASK,
--- if_bgereg.h.orig	Sun Dec 29 10:50:06 2002
+++ if_bgereg.h	Wed Jan  1 04:50:56 2003
@@ -1787,6 +1787,10 @@
  #define BCOM_DEVICEID_BCM5702X		0x16A6
  #define BCOM_DEVICEID_BCM5703X		0x16A7

+#define BCOM_SUBSYSID_UNKNOWN_0x0124	0x0124
+#define BCOM_SUBSYSID_UNKNOWN_0x0126	0x0126
+#define BCOM_SUBSYSID_UNKNOWN_0x1646	0x1646
+
  /*
   * Alteon AceNIC PCI vendor/device ID.
   */



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3E188CA8.5000900>