NetBSD Problem Report #29629

From www@netbsd.org  Tue Mar  8 13:33:46 2005
Return-Path: <www@netbsd.org>
Received: by narn.netbsd.org (Postfix, from userid 31301)
	id 11B1A63B116; Tue,  8 Mar 2005 13:33:46 +0000 (UTC)
Message-Id: <20050308133346.11B1A63B116@narn.netbsd.org>
Date: Tue,  8 Mar 2005 13:33:46 +0000 (UTC)
From: florence.henry@obspm.fr
Reply-To: florence.henry@obspm.fr
To: gnats-bugs@netbsd.org
Subject: PCI driver stge does not function with 2.0.1
X-Send-Pr-Version: www-1.0

>Number:         29629
>Category:       kern
>Synopsis:       PCI driver stge does not function with 2.0.1
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Mar 08 13:34:00 +0000 2005
>Last-Modified:  Sun Feb 26 06:29:45 +0000 2012
>Originator:     Florence HENRY
>Release:        NetBSD 2.0.1
>Organization:
Observatoire de Paris
>Environment:
NetBSD otarie.obspm.fr 2.0.1 NetBSD 2.0.1 (OTARIE) #0: Tue Mar  8 11:22:01 CET 2005  root@otarie.obspm.fr:/usr/src/sys/arch/i386/compile/OTARIE i386

(OTARIE is a copy of GENERIC)
>Description:
The ethernet PCI card "D-Link DGE 550T" does not work.

It is well recognized at boot time :

stge0 at pci2 dev 2 function 0: D-Link DL-4000 Gigabit Ethernet, rev. 12
stge0: interrupting at irq 10
stge0: Ethernet address 00:0f:3d:cd:e9:26
makphy0 at stge0 phy 1: Marvell 88E1000 Gigabit PHY, rev. 4
makphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 1000baseT-FDX, auto

ifconfig reports that it should be ok :

stge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        capabilities=7<IP4CSUM,TCP4CSUM,UDP4CSUM>
        enabled=0
        address: 00:0f:3d:cd:e9:26
        media: Ethernet 100baseTX full-duplex (1000baseT full-duplex)
        status: active
        inet 10.0.3.1 netmask 0xffffff00 broadcast 10.0.3.255
        inet6 fe80::20f:3dff:fecd:e926%stge0 prefixlen 64 scopeid 0x1

But it is impossible to send any packet trough this interface :

---
Listening to the stge0 interface and sending a ping to a machine located on the same private network (10.0.3.3), and linked directly with a cross-cable to the D-link card :

# /root # tcpdump -i stge0 
tcpdump: listening on stge0
14:19:02.358978 arp who-has 10.0.3.1 tell 10.0.3.3
14:19:02.358986 10.0.3.1 > 10.0.3.3: icmp: echo request seq 5
14:19:02.358988 arp reply 10.0.3.1 is-at 0:f:3d:cd:e9:26
14:19:07.393062 arp who-has 10.0.3.1 tell 10.0.3.3
14:19:07.393072 arp reply 10.0.3.1 is-at 0:f:3d:cd:e9:26

# /root # ping 10.0.3.3
PING 10.0.3.3 (10.0.3.3): 56 data bytes
ping: sendto: Host is down
ping: sendto: Host is down
ping: sendto: Host is down
ping: sendto: Host is down
ping: sendto: Host is down

---
Listening to the stge0 interface and sending a ping from 10.0.3.3 :

# /root # tcpdump -i stge0 
tcpdump: listening on stge0
14:18:31.325929 arp who-has 10.0.3.3 tell 10.0.3.1
14:18:32.330039 arp who-has 10.0.3.3 tell 10.0.3.1
14:18:33.340026 arp who-has 10.0.3.3 tell 10.0.3.1
14:18:34.340024 arp who-has 10.0.3.3 tell 10.0.3.1
14:18:35.340025 arp who-has 10.0.3.3 tell 10.0.3.1

The ping on the 10.0.3.3 machine results in a timeout, with 100.0% packet loss.

So it seems that the card hears well but cannot talk...

(sorry for the kern/29627 sent by mistake before finishing the report)
>How-To-Repeat:

>Fix:

>Release-Note:

>Audit-Trail:
From: Florence HENRY <florence.henry@obspm.fr>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: kern/29629
Date: Wed, 09 Mar 2005 14:45:53 +0100

 I have some more information to provide : when I make a "ping 10.0.3.1"
 from 10.0.3.3, and if I wait a long time (around 5 minutes), I get this
 message on the console :

 stge0: device timeout
 stge0: DMA wait timed out


 -- 
 Florence Henry
 florence.henry@obspm.fr

From: Florence HENRY <florence.henry@obspm.fr>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: kern/29629
Date: Wed, 09 Mar 2005 14:47:01 +0100

 Again some more information :

 I upgraded my kernel into -current :

 NetBSD otarie.obspm.fr 2.99.16 NetBSD 2.99.16 (GENERIC) #5: Wed Mar  9 
 12:14:22 CET 2005 
 root@otarie.obspm.fr:/usr/obj/sys/arch/i386/compile/GENERIC i386

 and I got the same bad results

 -- 
 Florence Henry
 florence.henry@obspm.fr

From: Manuel Bouyer <bouyer@antioche.lip6.fr>
To: gnats-bugs@NetBSD.org
Cc: kern-bug-people@NetBSD.org, gnats-admin@NetBSD.org,
	netbsd-bugs@NetBSD.org
Subject: Re: kern/29629: PCI driver stge does not function with 2.0.1
Date: Wed, 9 Mar 2005 17:34:20 +0100

 On Tue, Mar 08, 2005 at 01:34:00PM +0000, florence.henry@obspm.fr wrote:
 > The ethernet PCI card "D-Link DGE 550T" does not work.
 > 
 > It is well recognized at boot time :
 > 
 > stge0 at pci2 dev 2 function 0: D-Link DL-4000 Gigabit Ethernet, rev. 12
 > stge0: interrupting at irq 10
 > stge0: Ethernet address 00:0f:3d:cd:e9:26
 > makphy0 at stge0 phy 1: Marvell 88E1000 Gigabit PHY, rev. 4
 > makphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 1000baseT-FDX, auto
 > 
 > ifconfig reports that it should be ok :
 > 
 > stge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
 >         capabilities=7<IP4CSUM,TCP4CSUM,UDP4CSUM>
 >         enabled=0
 >         address: 00:0f:3d:cd:e9:26
 >         media: Ethernet 100baseTX full-duplex (1000baseT full-duplex)

 Hum, it looks like you selected 100baseTX full-duplex, but the adapter
 thinks it's in 1000baseT full-duplex mode. I don't know if it's the
 real cause of your problem, or just that the driver doesn't update the
 values passed to ifconfig properly.
 What happens if you use 'media autoselect' ?

 >         inet 10.0.3.1 netmask 0xffffff00 broadcast 10.0.3.255

 > ---
 > Listening to the stge0 interface and sending a ping to a machine located on the same private network (10.0.3.3), and linked directly with a cross-cable to the D-link card :
 > 
 > # /root # tcpdump -i stge0 
 > tcpdump: listening on stge0
 > 14:19:02.358978 arp who-has 10.0.3.1 tell 10.0.3.3
 > 14:19:02.358986 10.0.3.1 > 10.0.3.3: icmp: echo request seq 5
 > 14:19:02.358988 arp reply 10.0.3.1 is-at 0:f:3d:cd:e9:26
 > 14:19:07.393062 arp who-has 10.0.3.1 tell 10.0.3.3
 > 14:19:07.393072 arp reply 10.0.3.1 is-at 0:f:3d:cd:e9:26
 > 
 > # /root # ping 10.0.3.3
 > PING 10.0.3.3 (10.0.3.3): 56 data bytes
 > ping: sendto: Host is down
 > ping: sendto: Host is down
 > ping: sendto: Host is down
 > ping: sendto: Host is down
 > ping: sendto: Host is down
 > 
 > ---
 > Listening to the stge0 interface and sending a ping from 10.0.3.3 :
 > 
 > # /root # tcpdump -i stge0 
 > tcpdump: listening on stge0
 > 14:18:31.325929 arp who-has 10.0.3.3 tell 10.0.3.1
 > 14:18:32.330039 arp who-has 10.0.3.3 tell 10.0.3.1
 > 14:18:33.340026 arp who-has 10.0.3.3 tell 10.0.3.1
 > 14:18:34.340024 arp who-has 10.0.3.3 tell 10.0.3.1
 > 14:18:35.340025 arp who-has 10.0.3.3 tell 10.0.3.1
 > 
 > The ping on the 10.0.3.3 machine results in a timeout, with 100.0% packet loss.
 > 
 > So it seems that the card hears well but cannot talk...

 What does 'netstat -i' show on the stge0 interface ?

 -- 
 Manuel Bouyer <bouyer@antioche.eu.org>
      NetBSD: 26 ans d'experience feront toujours la difference
 --

From: Florence HENRY <florence.henry@obspm.fr>
To: gnats-bugs@NetBSD.org
Cc: kern-bug-people@NetBSD.org, gnats-admin@NetBSD.org,
	netbsd-bugs@NetBSD.org
Subject: Re: kern/29629
Date: Thu, 10 Mar 2005 12:27:08 +0100

 On Thu, Mar 10, 2005, Manuel Bouyer <bouyer@antioche.lip6.fr> wrote:

 >  > stge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
 >  >         capabilities=7<IP4CSUM,TCP4CSUM,UDP4CSUM>
 >  >         enabled=0
 >  >         address: 00:0f:3d:cd:e9:26
 >  >         media: Ethernet 100baseTX full-duplex (1000baseT full-duplex)
 > 
 >  
 >  Hum, it looks like you selected 100baseTX full-duplex, but the adapter
 >  thinks it's in 1000baseT full-duplex mode. I don't know if it's the
 >  real cause of your problem, or just that the driver doesn't update the
 >  values passed to ifconfig properly.
 >  What happens if you use 'media autoselect' ?

 I tried to force it in 100baseTX because the man page says :
 << The stge driver does not yet function properly with 1000BASE-T fitted
       boards.  Currently, only 1000BASE-SX boards work >>


 # /root # ifconfig stge0 media autoselect
 # /root # ifconfig stge0
 stge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
          capabilities=7<IP4CSUM,TCP4CSUM,UDP4CSUM>
          enabled=0
          address: 00:0f:3d:cd:e9:26
          media: Ethernet autoselect (1000baseT full-duplex)
          status: active
          inet 10.0.3.1 netmask 0xffffff00 broadcast 10.0.3.255
          inet6 fe80::20f:3dff:fecd:e926%stge0 prefixlen 64 scopeid 0x1


 A "ping 10.0.3.3" from the netbsd box gives :

 # /root # tcpdump -i stge0
 tcpdump: listening on stge0
 11:13:45.774716 10.0.3.1 > 10.0.3.3: icmp: echo request seq 0
 11:13:46.778739 10.0.3.1 > 10.0.3.3: icmp: echo request seq 1
 11:13:47.788749 10.0.3.1 > 10.0.3.3: icmp: echo request seq 2
 11:13:48.788770 10.0.3.1 > 10.0.3.3: icmp: echo request seq 3
 11:13:49.788778 10.0.3.1 > 10.0.3.3: icmp: echo request seq 4
 11:13:50.788806 10.0.3.1 > 10.0.3.3: icmp: echo request seq 5

 A "ping 10.0.3.1" from the other machine gives :

 # /root # tcpdump -i stge0
 tcpdump: listening on stge0
 11:15:43.648699 arp who-has 10.0.3.1 tell 10.0.3.3
 11:15:43.648707 arp reply 10.0.3.1 is-at 0:f:3d:cd:e9:26
 11:15:48.867245 arp who-has 10.0.3.1 tell 10.0.3.3
 11:15:48.867252 arp reply 10.0.3.1 is-at 0:f:3d:cd:e9:26
 11:15:54.367078 arp who-has 10.0.3.1 tell 10.0.3.3
 11:15:54.367085 arp reply 10.0.3.1 is-at 0:f:3d:cd:e9:26


 Something strange happens when I switched to media autoselect.

 Each time I made a "tcpdump -i stge0", the interface was broken for a 
 small amount of time (a fraction of a second).

 The 10.0.3.1 machine is a WinXP box, and each time the tcpdump command 
 was executed, it was complaining that the cable was unplugged. After a 
 fraction of a second, it was saying that the cable was plugged again, 
 and that the box was connected at 1Gb/s.

 This phenomenon does not accur when I switch to 100baseTX.

 >  What does 'netstat -i' show on the stge0 interface ?

 # /root # netstat -i 

 Name  Mtu   Network    Address             Ipkts Ierrs Opkts Oerrs Colls
 stge0 1500  <Link>     00:0f:3d:cd:e9:26     309     0     0     0     0
 stge0 1500  10.0.3/24  10.0.3.1              309     0     0     0     0
 stge0 1500  fe80::     fe80::20f:3dff:fe     309     0     0     0     0
 wm0   1500  <Link>     00:0c:f1:72:85:ae 5200474     0 688763    0     0
 wm0   1500  145.238/16 localhost         5200474     0 688763    0     0
 wm0   1500  fe80::     fe80::20c:f1ff:fe 5200474     0 688763    0     0

 The wm0 interface is the one that works.

 -- 
 Florence Henry
 florence.henry@obspm.fr

>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.