Date: Mon, 30 Jan 2006 23:57:42 +0300 From: Oleg Bulyzhin <oleg@freebsd.org> To: husnu demir <hdemir@metu.edu.tr> Cc: stable@freebsd.org, Gleb Smirnoff <glebius@freebsd.org> Subject: Re: if_bge driver problem. - Upgrade to RELEASE :) Message-ID: <20060130205742.GB82483@lath.rinet.ru> In-Reply-To: <20060129144448.GA1077392@metu.edu.tr> References: <20060127122438.GA1044592@metu.edu.tr> <20060127153512.GX83922@FreeBSD.org> <20060127161151.GA1093828@metu.edu.tr> <20060127161348.GA83922@cell.sick.ru> <20060127162904.GA1224732@metu.edu.tr> <20060128080843.GA22614@lath.rinet.ru> <20060129144448.GA1077392@metu.edu.tr>
next in thread | previous in thread | raw e-mail | index | archive | help
--neYutvxvOLaeuPCA Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Sun, Jan 29, 2006 at 04:44:48PM +0200, husnu demir wrote: > On Sat, Jan 28, 2006 at 11:08:43AM +0300, Oleg Bulyzhin wrote: > > On Fri, Jan 27, 2006 at 06:29:04PM +0200, husnu demir wrote: > > > > Also it is important to know whether doing 'ifconfig bge0 -rxcsum -txcsum' > > > > fixes operation on 6.0-STABLE. > > > > > > No, It does not fixed. I will go back to STABLE if you need further detail. > > > > > > > Could you please provide following information: > > 1) boot with verbose mode on (boot -v or verbose_loading="YES" into your > > loader.conf) and check your console messages. Are there any > > "bge2: link UP/DOWN" messages? Unplug/plug cable and check those messages again. > > > > 2) When you sniff bge2 with tcpdump which packets do you see (incoming, outgoing, both)? > > > > -- > > Oleg. > > Hi Oleg, > > I added ; > > root@~# less /boot/loader.conf > verbose_loading="YES > > > and reboot the machine; > > root@~# uname -a > FreeBSD nrouter.cc.metu.edu.tr 6.0-STABLE FreeBSD 6.0-STABLE #1: Sun Jan 29 16:29:48 EET 2006 root@nrouter.cc.metu.edu.tr:/usr/obj/usr/src/sys/NON-GENERIC i386 > > and dmesg shows nothing. After reboot I configured bge2 with ; > > ifconfig bge2 xxx.yyy.2.2/24 up > > root@~# dmesg | grep bge > bge0: <Broadcom BCM5703 Gigabit Ethernet, ASIC rev. 0x1002> mem 0xf1020000-0xf102ffff irq 48 at device 1.0 on pci3 > miibus0: <MII bus> on bge0 > bge0: Ethernet address: 00:11:09:9b:6a:7d > bge1: <Broadcom BCM5701 Gigabit Ethernet, ASIC rev. 0x105> mem 0xf1000000-0xf100ffff irq 52 at device 2.0 on pci3 > miibus1: <MII bus> on bge1 > bge1: Ethernet address: 00:04:76:f7:99:6e > bge2: <Broadcom BCM5703 Gigabit Ethernet, ASIC rev. 0x1002> mem 0xf1010000-0xf101ffff irq 56 at device 3.0 on pci3 > bge2: Ethernet address: 00:10:18:00:4d:53 > bge0: link state changed to UP > > then I tried to remove the fiber optic connection from the card and reinsert but there was no error messages. I tried it a couple of times. It shows "no carrier" message in the ifconfig status but print no console message. > > > I also added the tcpdump; before starting out tcpdump I initiated a ping xxx.yyy.2.1 for the outgoing messages. No PF working . > > > > root@~# pfctl -d > pfctl: pf not enabled > Could you apply attached patch and try those tests again (verbose boot, plug/unplug cable, check for link messages)? -- Oleg. --neYutvxvOLaeuPCA Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="bge_tbi-link.patch" Index: if_bge.c =================================================================== RCS file: /home/ncvs/src/sys/dev/bge/if_bge.c,v retrieving revision 1.91.2.10 diff -u -r1.91.2.10 if_bge.c --- if_bge.c 30 Jan 2006 13:17:44 -0000 1.91.2.10 +++ if_bge.c 30 Jan 2006 20:53:54 -0000 @@ -3769,23 +3769,9 @@ } if (sc->bge_tbi) { - /* - * Sometimes PCS encoding errors are detected in - * TBI mode (on fiber NICs), and for some reason - * the chip will signal them as link changes. - * If we get a link change event, but the 'PCS - * encoding error' bit in the MAC status register - * is set, don't bother doing a link check. - * This avoids spurious "link UP" messages - * that sometimes appear on fiber NICs during - * periods of heavy traffic. (There should be no - * effect on copper NICs.) - */ status = CSR_READ_4(sc, BGE_MAC_STS); - if (!(status & (BGE_MACSTAT_PORT_DECODE_ERROR| - BGE_MACSTAT_MI_COMPLETE))) { - if (!sc->bge_link && - (status & BGE_MACSTAT_TBI_PCS_SYNCHED)) { + if (status & BGE_MACSTAT_TBI_PCS_SYNCHED) { + if (!sc->bge_link) { sc->bge_link++; if (sc->bge_asicrev == BGE_ASICREV_BCM5704) BGE_CLRBIT(sc, BGE_MAC_MODE, @@ -3793,11 +3779,13 @@ CSR_WRITE_4(sc, BGE_MAC_STS, 0xFFFFFFFF); if (bootverbose) if_printf(sc->bge_ifp, "link UP\n"); - } else if (sc->bge_link) { - sc->bge_link = 0; - if (bootverbose) - if_printf(sc->bge_ifp, "link DOWN\n"); + if_link_state_change(sc->bge_ifp, LINK_STATE_UP); } + } else if (sc->bge_link) { + sc->bge_link = 0; + if (bootverbose) + if_printf(sc->bge_ifp, "link DOWN\n"); + if_link_state_change(sc->bge_ifp, LINK_STATE_DOWN); } } else { /* --neYutvxvOLaeuPCA--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060130205742.GB82483>