Array 5 liveCD - report (X11, ide issues; suspend success)
Zack Weinberg
zack at codesourcery.com
Tue Mar 1 17:45:52 CST 2005
[Reminder: I am not subscribed to ubuntu-devel; please cc: me on
responses.]
Colin Watson wrote:
> The installer uses a custom program in netcfg called ethtool-lite, which
> combines the functionality of mii-diag and ethtool. It just does a
> couple of ioctls. Its log messages should still be around in
> /var/log/installer/syslog.
I don't see any log messages from ethtool-lite in that file. I see
main-menu: DEBUG: Menu item 'netcfg' selected
main-menu: DEBUG: configure netcfg, status: 2
main-menu: DEBUG: configure libc6, status: 0
main-menu: DEBUG: virtual package libc6
main-menu: DEBUG: configure libdebconfclient0, status: 0
main-menu: DEBUG: virtual package libdebconfclient0
main-menu: DEBUG: configure libdebian-installer4, status: 0
main-menu: DEBUG: virtual package libdebian-installer4
main-menu: DEBUG: configure libiw27, status: 0
main-menu: DEBUG: virtual package libiw27
main-menu: DEBUG: configure ethernet-card-detection, status: 0
main-menu: DEBUG: virtual package ethernet-card-detection
dhclient: Internet Software Consortium DHCP Client 2.0pl5
... dhclient banner ...
dhclient: Listening on LPF/eth0/<addr>
dhclient: Sending on LPF/eth0/<addr>
dhclient: Sending on Socket/fallback/fallback-net
dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 3
dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 8
dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 12
netcfg: INFO: Detected eth0 as a hotpluggable device
... after which, main-menu logs a duplicate of the dhclient
information, and then goes on to the next thing.
After some head-scratching, I figured out that ethtool-lite was
compiled into the 'netcfg' binary and that I could get a usable
standalone executable from the netcfg source package. This is what it
prints when invoked against the built-in ethernet interface, while it
is down and not connected to anything:
# gcc -DTEST ethtool-lite.c -o etl
# ./etl eth0; echo $?
ethtool ioctl on eth0 failed
eth0 is connected. (MII)
0
Somewhat redacted strace:
# strace ./etl eth0
...
socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 3
ioctl(3, SIOCETHTOOL, 0xbfffac0) = -1 EOPNOTSUPP (Operation not supported)
write(1, "ethtool ioctl on side failed\n", 29) = 29
ioctl(3, SIOCGMIIPHY, 0xbfffac0) = 0
ioctl(3, SIOCGMIIREG, 0xbfffac0) = 0
write(1, "side is connected. (MII)\n", 25) = 25
Compare mii-diag:
# mii-diag eth0; echo $?
Basic registers of MII PHY #24: ffff ffff ffff ffff ffff ffff ffff ffff.
No MII transciever present!
Use '--force' to view the information anyway.
0
Further experimentation reveals that this driver (3c59x) will report
correct link-beat information via the MII interface if the interface
has been subjected to "ifconfig up", but not if it is "down". That is
arguably a kernel bug, but it should be easy to work around in
netcfg...? Also, perhaps ethtool-lite should be validating the MII
result a little more thoroughly?
zw
More information about the ubuntu-devel
mailing list