From 7430b0b9ec5267e1a4db08d662dd1e3e644534b9 Mon Sep 17 00:00:00 2001 From: "Mark D. Studebaker" Date: Thu, 11 May 2000 01:44:14 +0000 Subject: [PATCH] (mds) add driver name for adm1025 detection. git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@802 7894878c-1315-0410-8ee3-d5d059ff63e0 --- prog/detect/sensors-detect | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/prog/detect/sensors-detect b/prog/detect/sensors-detect index e17b8cdd..08644ef8 100755 --- a/prog/detect/sensors-detect +++ b/prog/detect/sensors-detect @@ -402,8 +402,8 @@ use subs qw(lm78_detect lm78_isa_detect lm78_alias_detect lm75_detect }, { name => "Analog Devices ADM1025", -# driver => "xxxxxxx", - i2c_addrs => [0x2c..0x2f], + driver => "adm1025", + i2c_addrs => [0x2c..0x2e], i2c_detect => sub { adm1025_detect 0, @_ } }, { @@ -1624,7 +1624,6 @@ sub adm1022_detect ($chip == 1 and $reg == 0x49); return unless (i2c_smbus_read_byte_data($file,0x40) & 0x80) == 0x00; return unless (i2c_smbus_read_byte_data($file,0x3f) & 0xc0) == 0xc0; - return (8); } @@ -1643,10 +1642,9 @@ sub adm1025_detect my $reg; my ($chip, $file,$addr) = @_; $reg = i2c_smbus_read_byte_data($file,0x3e); - return unless ($chip == 0 and $reg == 0x41); + return unless ($reg == 0x41); return unless (i2c_smbus_read_byte_data($file,0x40) & 0x80) == 0x00; return unless (i2c_smbus_read_byte_data($file,0x3f) & 0xc0) == 0x20; - return (8); }