mirror of
https://github.com/lm-sensors/lm-sensors
synced 2025-09-02 23:35:57 +00:00
Improve handling of special-case bus driver names:
* Drop support for temporarily disabling I2C bus drivers - we've not used it for years. * Handle the other special cases early, so that later code no longer needs to care. git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@5222 7894878c-1315-0410-8ee3-d5d059ff63e0
This commit is contained in:
@@ -74,7 +74,6 @@ $revision =~ s/ \([^()]*\)//;
|
|||||||
devid => 0x7603,
|
devid => 0x7603,
|
||||||
procid => "Intel 82372FB PIIX5 ACPI",
|
procid => "Intel 82372FB PIIX5 ACPI",
|
||||||
driver => "to-be-tested",
|
driver => "to-be-tested",
|
||||||
match => qr/^SMBus PIIX4 adapter at /,
|
|
||||||
} ,
|
} ,
|
||||||
{
|
{
|
||||||
vendid => 0x8086,
|
vendid => 0x8086,
|
||||||
@@ -2694,8 +2693,10 @@ sub adapter_pci_detection
|
|||||||
$key = sprintf("%04x:%04x", $try->{vendid}, $try->{devid});
|
$key = sprintf("%04x:%04x", $try->{vendid}, $try->{devid});
|
||||||
if (exists $pci_list{$key}) {
|
if (exists $pci_list{$key}) {
|
||||||
$device = $pci_list{$key};
|
$device = $pci_list{$key};
|
||||||
printf "Use driver `\%s' for device \%s: \%s\n",
|
if ($try->{driver} =~ m/^to-be-/) {
|
||||||
$try->{driver}, pci_busid($device), $try->{procid};
|
printf "No known driver for device \%s: \%s\n",
|
||||||
|
pci_busid($device), $try->{procid};
|
||||||
|
|
||||||
if ($try->{driver} eq "to-be-tested") {
|
if ($try->{driver} eq "to-be-tested") {
|
||||||
print "\nWe are currently looking for testers for this adapter!\n".
|
print "\nWe are currently looking for testers for this adapter!\n".
|
||||||
"Please check http://www.lm-sensors.org/wiki/Devices\n".
|
"Please check http://www.lm-sensors.org/wiki/Devices\n".
|
||||||
@@ -2704,7 +2705,11 @@ sub adapter_pci_detection
|
|||||||
<STDIN>;
|
<STDIN>;
|
||||||
print "\n";
|
print "\n";
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
printf "Use driver `\%s' for device \%s: \%s\n",
|
||||||
|
$try->{driver}, pci_busid($device), $try->{procid};
|
||||||
push @res, $try->{driver};
|
push @res, $try->{driver};
|
||||||
|
}
|
||||||
|
|
||||||
# Delete from detected SMBus device list
|
# Delete from detected SMBus device list
|
||||||
delete $smbus{$key};
|
delete $smbus{$key};
|
||||||
@@ -2719,7 +2724,7 @@ sub adapter_pci_detection
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (! @res) {
|
if (! @res) {
|
||||||
print "Sorry, no known PCI bus adapters found.\n";
|
print "Sorry, no supported PCI bus adapters found.\n";
|
||||||
}
|
}
|
||||||
return @res;
|
return @res;
|
||||||
}
|
}
|
||||||
@@ -5617,10 +5622,6 @@ sub generate_modprobes
|
|||||||
next unless exists $adap->{nr_later} and $adap->{nr_later} == $i;
|
next unless exists $adap->{nr_later} and $adap->{nr_later} == $i;
|
||||||
if ($adap->{driver} eq "UNKNOWN") {
|
if ($adap->{driver} eq "UNKNOWN") {
|
||||||
$modprobes .= "# modprobe unknown adapter ".$adap->{name}."\n";
|
$modprobes .= "# modprobe unknown adapter ".$adap->{name}."\n";
|
||||||
} elsif ($adap->{driver} eq "DISABLED") {
|
|
||||||
$modprobes .= "# modprobe disabled adapter ".$adap->{name}."\n";
|
|
||||||
} elsif ($adap->{driver} eq "to-be-written") {
|
|
||||||
$modprobes .= "# no driver available for adapter ".$adap->{name}."\n";
|
|
||||||
} else {
|
} else {
|
||||||
$modprobes .= "modprobe $adap->{driver}\n"
|
$modprobes .= "modprobe $adap->{driver}\n"
|
||||||
unless $modprobes =~ /modprobe $adap->{driver}\n/;
|
unless $modprobes =~ /modprobe $adap->{driver}\n/;
|
||||||
@@ -5757,8 +5758,6 @@ sub main
|
|||||||
print "We will now try to load each adapter module in turn.\n"
|
print "We will now try to load each adapter module in turn.\n"
|
||||||
if (@adapters);
|
if (@adapters);
|
||||||
foreach $adapter (@adapters) {
|
foreach $adapter (@adapters) {
|
||||||
next if $adapter eq "DISABLED";
|
|
||||||
next if $adapter eq "to-be-tested";
|
|
||||||
if (exists($modules_list{$adapter})) {
|
if (exists($modules_list{$adapter})) {
|
||||||
print "Module `$adapter' already loaded.\n";
|
print "Module `$adapter' already loaded.\n";
|
||||||
} else {
|
} else {
|
||||||
|
Reference in New Issue
Block a user