Hello, I don't remember anymore when I reported it the first time. I think it was around 4.x or something like that. The em(4) bug is still there after years. Hasn't anyone really noticed yet that em(4) only appears when you boot FreeBSD with the interface physically attached to a switch for example? If you attach it later, after boot up, the interface won't power up and appear in the interface list (ifconfig)? Steps to reproduce: 1) Switch your PC/laptop off. Really OFF, no reboot. 2) Disconnect the em(4) NIC from your switch. 3) Boot FreeBSD. 4) Plug in the ethernet cable. 5) Tataa! All leds at the NIC stay off. You won't be able to use em(4) unless you reboot your machine. Something is not being initialized properly on em(4) devices, it seems. I have had 3 of 3 em(4) NICs so far, where this bug shows up. And it's extremely annoying on Thinkpads, when you just want to plug in your laptop somewhere. -- Martin -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 195 bytes Desc: not available Url : http://lists.freebsd.org/pipermail/freebsd-stable/attachments/20080801/bca7b993/signature.pgp
> Hasn't anyone really noticed yet that em(4) only appears when you boot > FreeBSD with the interface physically attached to a switch for example? > If you attach it later, after boot up, the interface won't power up and > appear in the interface list (ifconfig)?I'm afraid I don't see your problem at all. My em interfaces appear as they should, even if not connected to a switch. And when I connect an em interface to a switch, I get link and things work as expected.> Steps to reproduce: > 1) Switch your PC/laptop off. Really OFF, no reboot. > 2) Disconnect the em(4) NIC from your switch. > 3) Boot FreeBSD. > 4) Plug in the ethernet cable. > 5) Tataa! All leds at the NIC stay off. You won't be able to use em(4) > unless you reboot your machine. > > Something is not being initialized properly on em(4) devices, it seems.This may well be the case - but not that the em driver handles several different chip models. You may have a problem which is specific to one or a few chip models. Steinar Haug, Nethelp consulting, sthaug@nethelp.no
On Fri, Aug 01, 2008 at 02:20:05PM +0200, Martin wrote:> I don't remember anymore when I reported it the first time. I think it > was around 4.x or something like that. The em(4) bug is still there > after years. > > Hasn't anyone really noticed yet that em(4) only appears when you boot > FreeBSD with the interface physically attached to a switch for example? > If you attach it later, after boot up, the interface won't power up and > appear in the interface list (ifconfig)? > > Steps to reproduce: > 1) Switch your PC/laptop off. Really OFF, no reboot. > 2) Disconnect the em(4) NIC from your switch. > 3) Boot FreeBSD. > 4) Plug in the ethernet cable. > 5) Tataa! All leds at the NIC stay off. You won't be able to use em(4) > unless you reboot your machine. > > Something is not being initialized properly on em(4) devices, it seems.Generally speaking (with my other NICs, specifically Pro/1000 NICs), I have not seen this behaviour. The em(4) driver behaves very well and does 802.3u auto-neg of speed/duplex properly. I have used many different revisions of Pro/1000 on FreeBSD and haven't seen this behaviour. Most commonly what you're reporting is the result of a switch upstream which isn't fully compatible or properly doing 802.3u auto-neg. Rebooting the machine (thus tearing down link hard, and resetting the entire chip) often works in this situation. You can also try setting the speed and duplex (media and mediaopt) in your ifconfig_emX line in rc.conf to see if that helps (on some switches it does). The behaviour you're reporting I've seen on old 3Com XL 509x cards with Cisco switches, for example. I gladly await more flame mails from people telling me "Yes, that is a known problem with Cisco switches in the past, but it does not happen any more", but even present-day Cisco switches we use at our workplace (alongside em(4) NICs) behave erroneously just like "in the past". *shrug* Everyone has a different experience.> I have had 3 of 3 em(4) NICs so far, where this bug shows up. And it's > extremely annoying on Thinkpads, when you just want to plug in your > laptop somewhere.I have a Thinkpad T60p. I'll try booting FreeBSD on it next week and see if I can reproduce the behaviour. I'll also include what switch brands/models are being plugged into. -- | Jeremy Chadwick jdc at parodius.com | | Parodius Networking http://www.parodius.com/ | | UNIX Systems Administrator Mountain View, CA, USA | | Making life hard for others since 1977. PGP: 4BD6C0CB |
Hi, On 1 Aug 2008, at 13:20, Martin wrote:> > Hello, > > I don't remember anymore when I reported it the first time. I think it > was around 4.x or something like that. The em(4) bug is still there > after years. > > Hasn't anyone really noticed yet that em(4) only appears when you boot > FreeBSD with the interface physically attached to a switch for > example? > If you attach it later, after boot up, the interface won't power up > and > appear in the interface list (ifconfig)? > > Steps to reproduce: > 1) Switch your PC/laptop off. Really OFF, no reboot. > 2) Disconnect the em(4) NIC from your switch. > 3) Boot FreeBSD. > 4) Plug in the ethernet cable. > 5) Tataa! All leds at the NIC stay off. You won't be able to use em(4) > unless you reboot your machine. > > Something is not being initialized properly on em(4) devices, it > seems. > > I have had 3 of 3 em(4) NICs so far, where this bug shows up. And it's > extremely annoying on Thinkpads, when you just want to plug in your > laptop somewhere.Well it's not a problem for my TP T41 (just tested with 5.0R and 7.0R), the NIC probes as: <Intel (R) PRO/1000 Network Connection Version - 6.7.3> and I've never seen it on sundry other boxes with em. That doesn't mean it can't happen, of course.> -- > Martin-- Bob Bishop +44 (0)118 940 1243 rb@gid.co.uk fax +44 (0)118 940 1295 mobile +44 (0)783 626 4518
On Fri, 1 Aug 2008, Martin wrote:> I don't remember anymore when I reported it the first time. I think it was > around 4.x or something like that. The em(4) bug is still there after years. > > Hasn't anyone really noticed yet that em(4) only appears when you boot > FreeBSD with the interface physically attached to a switch for example? If > you attach it later, after boot up, the interface won't power up and appear > in the interface list (ifconfig)?The card range supported by the if_em driver is huge, so it wouldn't be surprising if this is a hardware bug affecting a relatively narrow line of parts. I've added Jack Vogel to the CC line, as he's the Intel developer responsible for maintaining our if_em driver. I don't promise he can help either, but it's worth a try :-). Robert> > Steps to reproduce: > 1) Switch your PC/laptop off. Really OFF, no reboot. > 2) Disconnect the em(4) NIC from your switch. > 3) Boot FreeBSD. > 4) Plug in the ethernet cable. > 5) Tataa! All leds at the NIC stay off. You won't be able to use em(4) > unless you reboot your machine. > > Something is not being initialized properly on em(4) devices, it seems. > > I have had 3 of 3 em(4) NICs so far, where this bug shows up. And it's > extremely annoying on Thinkpads, when you just want to plug in your > laptop somewhere. > > -- > Martin >
Martin <nakal@web.de> wrote:> On Sat, 02 Aug 2008 12:55:53 +0200 > Torfinn Ingolfsen <torfinn.ingolfsen@broadpark.no> wrote: > >> Just to be sure: also if the first command you try on the interface is >> 'ifconfig up'? > > Hello Torfinn, > > good point, no. The problem appears when the first thing called on this > interface is dhclient (caused by ifconfig_em0="DHCP"). I could also > provoke this behavior after the interface was once up had an IP and was > working (ping). All I need to do is to disconnect the NIC from the > switch when I type "/etc/rc.d/netif restart". > > I have noticed further strange effects here. The behavior seems to > be even more complex. > > After I typed "/etc/rc.d/netif restart", I waited until I get "giving > up" message. Then I plugged the cable in. After about 30 seconds the > link LED was on. I noticed that at this point I couldn't get an address > using DHCP. > > So I disconnected physically the NIC (no cable) and link LED was > still on! ifconfig showed me "state: active" with no cable plugged in. > After further 30 seconds the LED went off. > > I attached the NIC again to the switch again and after 30 seconds > again I got some other effect. The link LED went on (status: active) > and the data LED was permanently blinking (about 2,5 times a second). I > pulled the cable again and now the link LED is still on and the data > LED still blinking (since about 10 minutes already). > > By the way... > Now I'm typing this E-Mail without an ethernet cable plugged in and the > link status LED is still on and the other data LED is blinking. > > -- > Martin >I may have misunderstood the purpose of this, but do you have the bpf compiled into your kernel? If you're having DHCP troubles, this could be a problem. Chris
Mike Tancsa schrieb:> If you manually type, > dhclient em0No, even if I type ifconfig em0 down && ifconfig em0 up it won?t work. The interface just gets no link until I reload the driver with a cable plugged. -- Markus
> For what it's worth, I have a T60 that dual boots 6.3-R/amd64 and 7.0-R/i386 > and neither install has this problem. I can cold boot it with the NIC > unplugged, plug in a cable, I get a link light and ifconfig em0 goes to > active, dhclient em0 gets an IP successfully. >Did you try to run /etc/rc.d/netif start after you've booted your laptop unplugged? Try to do that, THEN connect the cable. The problem appears ONLY in this situation. And it's quite common, because you often use your laptop with wireless network and suddenly you decide to connect it to wired network without having to switch the laptop off. My NIC is in such a state that I am forced to switch it off, or else I don't get link signal. I don't think it's a BIOS firmware problem (I have tried every update). I can remember that Linux had this issues, too a while ago. It works there now, but FreeBSD is still the same. Please read the steps how I cause this situation. It appears ONLY when you do it like I described it. I've seen that people first boot with plugged in cable and start to play with dhclient. Both is wrong. Correct steps to reproduce is: You have to start with unhooked interface AND the line ifconfig_re0="DHCP" in /etc/rc.conf. Then wait until you can login and try to attach the cable. -- Martin _______________________________________________________________________ EINE F?R ALLE: die kostenlose WEB.DE-Plattform f?r Freunde und Deine Homepage mit eigenem Namen. Jetzt starten! http://unddu.de/?kid=kid@mf2