Unfortunately the reverse byte-ordering problem of the MAC address after
suspend is still present in Hardy (forcedeth driver), although perhaps
not in its original form.

If I suspend or hibernate the usual way, all is good. I need wake-on-
lan, however, and the net card must therefore first be put to sleep
(ACPI D3 state). Doing this, hibernate still works, but after resuming
from suspend, the byte-ordering of the MAC address is inverted, and the
interface gets a new name.

A simple workaround: Invert the byte ordering before putting the net
card to sleep. Some useful commands for the purpose:

ethtool -s eth0 wol g # enable wake-on-lan on eth0
ethtool -i eth0 | grep bus-info # Find PCI bus/device/function
Returns "bus-info: 0000:00:04.0 (bus 0, device 4, function 0)" in my case.
pci-config is used to set power state to D3, but first the ID must be 
identified based on the bus-info. List IDs for bus 0:
pci-config -B0 -a
Returns  "Device #12 at bus 0 device/function 4/0, 006610de".
Shutdown eth0 and reverse MAC address to avoid problems after resume:
ifconfig eth0 down hw ether 08:f6:11:6e:0c:00 # hw MAC is 00:0c:6e:11:f6:08
Set power state of device #12 to D3:
pci-config -B0 -S -#12
Now suspend or hibernate.
Please note that in order to wake up the machine, you need to use the reversed 
MAC address:
etherwake 08:f6:11:6e:0c:00
All is well after the wake-up call, but without the MAC reversal above, eth0 
would be lost after suspend (in any case eth0 needs to be shut down, otherwise 
the machine will hang when the NIC power state is changed).

I am happy with my work-around, so I am not eager to try out patches
(and my experience with kernel patching is very limited). Also, I am not
sure where this bug should be reported.

Thanks,
Lars

Details:
Motherboard: Asus A7N8X Deluxe
Linux corolla 2.6.24-19-generic #1 SMP Fri Jul 11 23:41:49 UTC 2008 i686 
GNU/Linux
00:04.0 Ethernet controller: nVidia Corporation nForce2 Ethernet Controller 
(rev a1)
pci-config is at ftp://ftp.scyld.com/pub/diag/pci-config.c and the power-down 
procedure was inspired by 
http://www.nvnews.net/vbulletin/archive/index.php/t-21578.html

-- 
first eth device gets new number on resume
https://bugs.launchpad.net/bugs/175333
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to