# Kernel upgrade causes network problem

## nyk

I have a PCI network card that reported by lspci like this: Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+

I use the 8139too driver of kernel 2.6.12-ck6 and it works perfectly.

Now I try to upgrade to kernel 2.6.13-ck6 by copying over the .config, running "make oldconfig" and hitting "n" to all new stuff (including premptiveness). But when I run this new kernel, DHCP doesn't work anymore! What could cause this? I can just keep using the old kernel, but this seems to be a bug or something, because I have the same .config.

----------

## mw007

Do you have the driver compiled into the kernel, or as a module? If it's as a module, then I would guess that the module isn't being loaded at boot.

----------

## nyk

I have it compiled in... I mean I don't want to set any module parameters, so I just leave it always in.

----------

## Relian

I had the same problem, after an upgrade of the kernel all was ok but i was not able to reach any other pc on my network.

After a fast check i found that the kernel disabled irq5 (the one assigned to my network card used by the 8139too module),

No way to change irq to the modules or by bios (kernel disabled the new irq  :Sad:  ), i was not able to use my network.

Finally today i have found the problem, GCC-3.4.4.

If i compile the new kernel with GCC-3.3.6 all is ok, no irq disable and network works. No way to use GCC-3.4.4, every kernel 2.6.12.X/2.6.13.X give me the same problem (irq5 disable, no errors but network is not working).

So, if you have compiled your kernel with GCC-3.4.4, try another version.

----------

## nyk

Thanks for the advice!

I'm now doing emerging gcc 3.3.5 since this version may also fix the xorg-x11 bug where transparency turns black (https://forums.gentoo.org/viewtopic-t-386761-highlight-.html).

This takes some time...  :Smile: 

----------

## nyk

Compiling with gcc 3.3 didn't make it work, so I switched back to the current version 3.4.4. 

But the network card is still not working in linux-2.6.13-gentoo-r3. Any more ideas how to fix it?

----------

## Cybersorcerer

Hi nyk,

i am not sure what you mean by dhcp not working. I assume you can't get an ip address.

I think we need some more information ... anything in syslog ? What about dmesg outmput ?

Also ifconfig -a would be nice.

----------

## jpalko

This is indeed an interesting functionality problem, I have a motherboard which has a Marvell Technology Group Ltd. 88E8001 Gigabit Ethernet Controller (rev 13) and an additional Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+ (rev 10) ethernet card which I meant to use on my new firewall as the outwards ethernet. I have installed the system with amd64 minimal livecd. The installation CD got the ethernet working great with both interfaces, but now the gentoo-sources-2.6.13-r3 doesn't get this going...

Some information on the devices:

```
fw2 ~ # lspci -vv -s 00:0a.0

0000:00:0a.0 Ethernet controller: Marvell Technology Group Ltd. 88E8001 Gigabit Ethernet Controller (rev 13)

        Subsystem: ASUSTeK Computer Inc. Marvell 88E8001 Gigabit Ethernet Controller (Asus)

        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV+ VGASnoop- ParErr- Stepping- SERR+ FastB2B-

        Status: Cap+ 66Mhz+ UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-

        Latency: 64 (5750ns min, 7750ns max), cache line size 10

        Interrupt: pin A routed to IRQ 193

        Region 0: Memory at fab00000 (32-bit, non-prefetchable) [size=16K]

        Region 1: I/O ports at b000 [size=256]

        Expansion ROM at faa00000 [disabled] [size=128K]

        Capabilities: [48] Power Management version 2

                Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)

                Status: D0 PME-Enable- DSel=0 DScale=1 PME-

        Capabilities: [50] Vital Product Data

fw2 ~ # lspci -vv -s 00:0e.0

0000:00:0e.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+ (rev 10)

        Subsystem: Realtek Semiconductor Co., Ltd. RT8139

        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR+ FastB2B-

        Status: Cap+ 66Mhz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-

        Latency: 64 (8000ns min, 16000ns max)

        Interrupt: pin A routed to IRQ 201

        Region 0: I/O ports at b400 [size=256]

        Region 1: Memory at fac00000 (32-bit, non-prefetchable) [size=256]

        Capabilities: [50] Power Management version 2

                Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=375mA PME(D0-,D1+,D2+,D3hot+,D3cold+)

                Status: D0 PME-Enable- DSel=0 DScale=0 PME-

fw2 ~ # cat /proc/interrupts

           CPU0

  0:     864766    IO-APIC-edge  timer

  8:          0    IO-APIC-edge  rtc

  9:          0   IO-APIC-level  acpi

 14:       6247    IO-APIC-edge  ide0

 15:         49    IO-APIC-edge  ide1

169:          0   IO-APIC-level  libata

177:          2   IO-APIC-level  ohci1394

185:        225   IO-APIC-level  ehci_hcd:usb1, uhci_hcd:usb2, uhci_hcd:usb3, uhci_hcd:usb4, uhci_hcd:usb5

193:       4292   IO-APIC-level  skge

NMI:         63

LOC:     864760

ERR:          0

MIS:          0
```

I did not exactly see there any 8139too interrupt information in /proc/interrupts even the lspci showed Interrupt: pin A routed to IRQ 201.

```
fw2 ~ # ifconfig -a

eth0      Link encap:Ethernet  HWaddr 00:11:D8:44:34:0F

          inet addr:192.168.0.42  Bcast:192.168.0.255  Mask:255.255.255.0

          inet6 addr: fe80::211:d8ff:fe44:340f/64 Scope:Link

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:2621 errors:0 dropped:0 overruns:0 frame:0

          TX packets:2148 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000

          RX bytes:537714 (525.1 Kb)  TX bytes:683341 (667.3 Kb)

          Interrupt:193

eth1      Link encap:Ethernet  HWaddr 00:40:F4:CD:B9:55

          BROADCAST MULTICAST  MTU:1500  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000

          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

          Interrupt:201 Base address:0xa000

lo        Link encap:Local Loopback

          inet addr:127.0.0.1  Mask:255.0.0.0

          inet6 addr: ::1/128 Scope:Host

          UP LOOPBACK RUNNING  MTU:16436  Metric:1

          RX packets:350 errors:0 dropped:0 overruns:0 frame:0

          TX packets:350 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0

          RX bytes:30581 (29.8 Kb)  TX bytes:30581 (29.8 Kb)

sit0      Link encap:IPv6-in-IPv4

          NOARP  MTU:1480  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0

          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
```

When I connect the ethernet to my ADSL box and run dhclient I get:

```
fw2 ~ # dhclient eth1

Internet Systems Consortium DHCP Client V3.0.1

Copyright 2004 Internet Systems Consortium.

All rights reserved.

For info, please visit http://www.isc.org/products/DHCP

sit0: unknown hardware address type 776

execve (/sbin/dhclient-script, ...): No such file or directory

sit0: unknown hardware address type 776

Listening on LPF/eth1/00:40:f4:cd:b9:55

Sending on   LPF/eth1/00:40:f4:cd:b9:55

Sending on   Socket/fallback

receive_packet failed on eth1: Network is down

DHCPDISCOVER on eth1 to 255.255.255.255 port 67 interval 5

send_packet: Network is down

DHCPDISCOVER on eth1 to 255.255.255.255 port 67 interval 9

send_packet: Network is down

DHCPDISCOVER on eth1 to 255.255.255.255 port 67 interval 15

send_packet: Network is down

DHCPDISCOVER on eth1 to 255.255.255.255 port 67 interval 13

send_packet: Network is down

DHCPDISCOVER on eth1 to 255.255.255.255 port 67 interval 13

send_packet: Network is down

DHCPDISCOVER on eth1 to 255.255.255.255 port 67 interval 6

send_packet: Network is down

No DHCPOFFERS received.

No working leases in persistent database - sleeping.

execve (/sbin/dhclient-script, ...): No such file or directory
```

dmesg information:

```
fw2 ~ # dmesg | grep eth

skge eth0: addr 00:11:d8:44:34:0f

skge eth0: enabling interface

skge eth0: Link is up at 100 Mbps, full duplex, flow control tx and rx

eth0: no IPv6 routers present

eth1: RealTek RTL8139 at 0xffffc2000003a000, 00:40:f4:cd:b9:55, IRQ 201

eth1:  Identified 8139 chip type 'RTL-8100B/8139D'
```

----------

## nyk

No one is apparently able to help... Maybe we should start a bug-report in the gentoo bugzilla?

----------

## loemmel

same problem here, did you find a solution?

----------

## C.M

I have the same problem, and I think it is something with dhcp choosing ipv6 over ipv4, and then failing because there is no ipv6 dhcp-server availible. Not sure what caused this to happen though.

Maybe this bug is related somehow?

/C.M

----------

## jpalko

Found my problem solution... In my case though it was not really a problem of the system...

It was just time to buy some new ethernet cables. Old ones had their connectors broken.   :Laughing: 

----------

## loemmel

it's not the ethernet cables here. It's wireless, and I'm trying to get into the network of the campus, I'm on.

Any other ideas?

----------

## oybed78

Any solution to this yet? 

I have the same problem, but with a 3Com 3c905B (Cyclone) NIC card.

----------

## loemmel

No solution yet...   :Crying or Very sad:   I have to switch to Windows to get into the Network.  :Sad: 

----------

## nyk

I don't have a solution, haven't had the time to look into it. 

But just use kernel 2.6.12 instead of 2.6.13! 

Then it works, and why would I need 2.6.13 anyway?

I'm still hoping that it's gonna work in 2.6.14 again...  :Smile: 

But this week, I will try to find if I can localize the problem maybe more accurately and at least file a bug report.

----------

## loemmel

 *nyk wrote:*   

> I don't have a solution, haven't had the time to look into it. 
> 
> But just use kernel 2.6.12 instead of 2.6.13! 
> 
> Then it works, and why would I need 2.6.13 anyway?
> ...

 

I am using a 2.6.12 kernel. So this can't be the solution for me.

Perhaps this is kernel-config related?

----------

## loemmel

the problem with 2.6.13 is, that you don't have to use -Dipw but -Dwext, so just change wpa_supplicant to this:

wpa_supplicant_eth1="-Dwext"

and it should work for 2.6.13 kernels.

but still having the problem:

I am connected to the network:

```
eth1      IEEE 802.11g  ESSID:"stud"  

          Mode:Managed  Frequency:2.437 GHz  Access Point: 00:13:C4:C3:86:D4   

          Bit Rate=54 Mb/s   Tx-Power=20 dBm   

          Retry limit:7   RTS thr:off   Fragment thr:off

          Encryption key:C5F5-37FD-8C62-10F7-2D78-8C22-15 [4]   Security mode:open

          Power Management:off

          Link Quality=91/100  Signal level=-37 dBm  Noise level=-85 dBm

          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0

          Tx excessive retries:0  Invalid misc:315   Missed beacon:15
```

wpa_cli shows me for status:

 *Quote:*   

> bssid=00:13:c4:c3:86:d4
> 
> ssid=stud
> 
> pairwise_cipher=NONE
> ...

 

So there seems to be everything okay.

but:

when I try to get an IpAdress for eth1 through dhclient i get the following:

```
Internet Systems Consortium DHCP Client V3.0.1

Copyright 2004 Internet Systems Consortium.

All rights reserved.

For info, please visit http://www.isc.org/products/DHCP

Listening on LPF/eth1/00:12:f0:a1:54:a9

Sending on   LPF/eth1/00:12:f0:a1:54:a9

Sending on   Socket/fallback

DHCPDISCOVER on eth1 to 255.255.255.255 port 67 interval 7

DHCPDISCOVER on eth1 to 255.255.255.255 port 67 interval 19

DHCPDISCOVER on eth1 to 255.255.255.255 port 67 interval 12

DHCPDISCOVER on eth1 to 255.255.255.255 port 67 interval 11

DHCPDISCOVER on eth1 to 255.255.255.255 port 67 interval 12

No DHCPOFFERS received.

No working leases in persistent database - sleeping.
```

Works without problems in Windoze.

And I don't get any messages in dmesg for ipw2200 or ieee80211.

really strange.

I'm still using a 2.6.12-gentoo-r1 kernel, perhaps I should try upgrading to 2.6.13 but I think it should work with 2.6.12 too.

```
emerge -pv ipw2200 wpa_supplicant ieee80211

[ebuild   R   ]  net-wireless/ipw2200-1.0.8  -debug -radiotap 0 kB

[ebuild     U ]  net-wireless/wpa_supplicant-0.4.6 [0.4.5]  -debug -gsm -madwifi +qt +readline +ssl 475 kB

[ebuild   R   ]  net-wireless/ieee80211-1.1.6  -debug 0 kB
```

any ideas?

thanks for any help.

btw:

wlan Is working at home with normal TKIP, no dhcp but fixed IP Adresses.

----------

## nyk

I added 

wpa_supplicant_eth0="-Dwext"

to my /etc/conf.d/net, but then it did still not work with 2.6.13.

Is this what you meant or something else?

----------

## loemmel

No, I thin -Dwext is for kernels 2.6.14 that use, the new integrated ipw module.

This isn't implented in 2.6.13. but I'm not shure about this.

I've tried both, 2.6.13 and 2.6.14 whithout any luck. sometimes I get a connection, when I try with /etc/init.d/net.eth0 and dhclient eth0 in the same time until I get an wpa_supplicant error for /etc/init.d/net.eth0 and then it works.

but that cannot be the solution...

----------

## nyk

Now it works again! I'm using 2.6.14-ck4. I'm not sure if it's just because of the new version because I also went though every option of kernel config again. I had to remove a lot of unnecessary drivers (forcedeth modules for example) of devices that I used or tried to use. Also had some stupid options set because of mostly taking the default when using "make oldconfig". And I think most inportant is that I turned on Plug&Play, which may have resolved an IRQ conflict that might have kept the network card from working.

----------

## loemmel

did you use the implented driver of ipw and ieee modules? or did you patch the kernel?

----------

## nyk

I don't use the ipw, but I use the IEEE module. I didn't patch the kernel other that using Con Kolivas' high performance patchset from portage (linux-2.6.14-ck4).

----------

## loemmel

okay, I might have a look at it. I never used any sources other than the gentoo-sources.

----------

## nyk

I don't think it has anything to do with the ck patchset, which might be a bit faster for desktop usage, but otherwise I noticed no difference to the normal gentoo kernel. Strange that it's on ~amd64, as I don't experienced that it's anymore unstable.

I think the problem was caused by my bad kernel config. That I didn't have Plug&Play activated could have caused IRQ conflict. That could have been responsible for DHCP not working, I read this somewhere.

----------

## pilla

mine is working with gentoo-sources-2.6.14-r2 and ck-sources 2.6.14-ck5/6.  However, I get some wierd kernel exceptions when I unplug my Atheros-based PCMCIA card.

----------

## pwiebe

I had a similar problem.  I'm running the 8139too driver with the 2.6.14.2 vanilla-sources.  I also had the pcmcia running at the default runlevel.  The pcmcia module, in my case, was the culprit that disabled IRQ 10 (8139too uses IRQ 10).  If I remove pcmcia from the default runlevel, the 8139too driver and dhcp works fine.

Now I've got to figure out how to get the two to work together.

----------

