mirror of
https://github.com/lm-sensors/lm-sensors
synced 2025-08-31 14:25:39 +00:00
Fixed previous sensors-detect correction :-(
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@775 7894878c-1315-0410-8ee3-d5d059ff63e0
This commit is contained in:
@@ -651,13 +651,16 @@ sub read_proc_pci
|
||||
open INPUTFILE, "/proc/pci" or return;
|
||||
while (<INPUTFILE>) {
|
||||
my $record = {};
|
||||
if (($record->{bus}+0,$record->{slot}+0,$record->{func}+0) =
|
||||
if (($record->{bus},$record->{slot},$record->{func}) =
|
||||
/^\s*Bus\s*(\S)+\s*,\s*device\s*(\S+)\s*,\s*function\s*(\S+)\s*:\s*$/) {
|
||||
my $desc = <INPUTFILE>;
|
||||
$_ = <INPUTFILE>;
|
||||
unless (($desc =~ /Unknown device/) and
|
||||
if (($desc =~ /Unknown device/) and
|
||||
(($record->{vendid},$record->{devid}) =
|
||||
/^\s*Vendor id=(\S+)\.\s*Device id=(\S+)\.$/)) {
|
||||
$record->{vendid} = hex $record->{vendid};
|
||||
$record->{devid} = hex $record->{devid};
|
||||
} else {
|
||||
$record->{desc} = $desc;
|
||||
}
|
||||
push @pci_list,$record;
|
||||
|
Reference in New Issue
Block a user