mirror of
https://github.com/lm-sensors/lm-sensors
synced 2025-08-31 06:15:15 +00:00
Refactor the detection of AMD CPU sensors.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@5957 7894878c-1315-0410-8ee3-d5d059ff63e0
This commit is contained in:
@@ -2177,7 +2177,7 @@ use vars qw(@cpu_ids);
|
||||
}, {
|
||||
name => "AMD K8 thermal sensors",
|
||||
driver => "k8temp",
|
||||
detect => \&k8temp_pci_detect,
|
||||
detect => sub { amd_pci_detect('1103') },
|
||||
}, {
|
||||
name => "AMD Family 10h thermal sensors",
|
||||
driver => "k10temp",
|
||||
@@ -2185,15 +2185,15 @@ use vars qw(@cpu_ids);
|
||||
}, {
|
||||
name => "AMD Family 11h thermal sensors",
|
||||
driver => "k10temp",
|
||||
detect => \&fam11h_pci_detect,
|
||||
detect => sub { amd_pci_detect('1303') },
|
||||
}, {
|
||||
name => "AMD Family 12h and 14h thermal sensors",
|
||||
driver => "k10temp",
|
||||
detect => \&fam12h_14h_pci_detect,
|
||||
detect => sub { amd_pci_detect('1703') },
|
||||
}, {
|
||||
name => "AMD Family 15h thermal sensors",
|
||||
driver => "k10temp",
|
||||
detect => \&fam15h_pci_detect,
|
||||
detect => sub { amd_pci_detect('1603') },
|
||||
}, {
|
||||
name => "Intel digital thermal sensor",
|
||||
driver => "coretemp",
|
||||
@@ -6110,9 +6110,10 @@ sub via8231_pci_detect
|
||||
return 9;
|
||||
}
|
||||
|
||||
sub k8temp_pci_detect
|
||||
sub amd_pci_detect
|
||||
{
|
||||
return unless exists $pci_list{'1022:1103'};
|
||||
my $f3_id = shift;
|
||||
return unless exists $pci_list{"1022:$f3_id"};
|
||||
return 9;
|
||||
}
|
||||
|
||||
@@ -6142,24 +6143,6 @@ sub fam10h_pci_detect
|
||||
return;
|
||||
}
|
||||
|
||||
sub fam11h_pci_detect
|
||||
{
|
||||
return unless exists $pci_list{'1022:1303'};
|
||||
return 9;
|
||||
}
|
||||
|
||||
sub fam12h_14h_pci_detect
|
||||
{
|
||||
return unless exists $pci_list{'1022:1703'};
|
||||
return 9;
|
||||
}
|
||||
|
||||
sub fam15h_pci_detect
|
||||
{
|
||||
return unless exists $pci_list{'1022:1603'};
|
||||
return 9;
|
||||
}
|
||||
|
||||
sub intel_amb_detect
|
||||
{
|
||||
if ((exists $pci_list{'8086:25f0'}) || # Intel 5000
|
||||
|
Reference in New Issue
Block a user