From 7b6557172aa0655fdee31b729d55a199158007d1 Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Wed, 9 Mar 2005 12:07:14 +0000 Subject: (get_eth_cards) update comments --- perl-install/network/ethernet.pm | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'perl-install/network') diff --git a/perl-install/network/ethernet.pm b/perl-install/network/ethernet.pm index 460457df7..3932cb332 100644 --- a/perl-install/network/ethernet.pm +++ b/perl-install/network/ethernet.pm @@ -51,12 +51,13 @@ sub get_eth_cards { return map { my $interface = $_; my $description; - # 0) get interface's driver through ETHTOOL ioctl or module aliases: + # 1) get interface's driver through ETHTOOL ioctl: my ($a, $detected_through_ethtool); $a = c::getNetDriver($interface); if ($a) { $detected_through_ethtool = 1; } else { + # 2) get interface's driver through module aliases: $a = $modules_conf->get_alias($interface); } @@ -71,16 +72,16 @@ sub get_eth_cards { ); $a = $fixes{$a} if exists $fixes{$a}; - # 1) try to match a PCMCIA device for device description: + # 3) try to match a PCMCIA device for device description: if (my $b = find { $_->{device} eq $interface } @devs) { # PCMCIA case $a = $b->{driver}; $description = $b->{description}; } else { - # 2) try to lookup a device by hardware address for device description: + # 4) try to lookup a device by hardware address for device description: # maybe should have we try sysfs first for robustness? ($description) = (mapIntfToDevice($interface))[0]->{description}; } - # 3) try to match a device through sysfs for driver & device description: + # 5) try to match a device through sysfs for driver & device description: # (eg: ipw2100 driver for intel centrino do not support ETHTOOL) if (!$description) { my $drv = readlink("/sys/class/net/$interface/driver"); @@ -93,7 +94,7 @@ sub get_eth_cards { $description = $cards[0]{description} if @cards == 1; } } - # 4) try to match a device by driver for device description: + # 6) try to match a device by driver for device description: # (eg: madwifi, ndiswrapper, ...) if (!$description) { my @cards = grep { $_->{driver} eq ($a || $saved_driver) } detect_devices::probeall(); -- cgit v1.2.1