2
0
mirror of https://github.com/lm-sensors/lm-sensors synced 2025-09-02 07:15:39 +00:00

recognize lm78's with chipid register (0x49) == 0x20, as

reported by Vernon McPherron <vernon@xnote.com>


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@998 7894878c-1315-0410-8ee3-d5d059ff63e0
This commit is contained in:
Mark D. Studebaker
2001-01-19 02:39:26 +00:00
parent d569353d79
commit c2b81edc8a
3 changed files with 7 additions and 5 deletions

View File

@@ -1503,7 +1503,7 @@ sub lm78_detect
return unless i2c_smbus_read_byte_data($file,0x48) == $addr;
return unless (i2c_smbus_read_byte_data($file,0x40) & 0x80) == 0x00;
$reg = i2c_smbus_read_byte_data($file,0x49);
return unless ($chip == 0 and $reg == 0x00) or
return unless ($chip == 0 and ($reg == 0x00 or $reg == 0x20)) or
($chip == 1 and $reg == 0x40) or
($chip == 2 and ($reg & 0xfe) == 0xc0);
return (7);
@@ -1529,7 +1529,7 @@ sub lm78_isa_detect
my $readproc = sub { isa_read_byte $addr + 5, $addr + 6, @_ };
return unless (&$readproc(0x40) & 0x80) == 0x00;
my $reg = &$readproc(0x49);
return unless ($chip == 0 and $reg == 0x00) or
return unless ($chip == 0 and ($reg == 0x00 or $reg == 0x20)) or
($chip == 1 and $reg == 0x40) or
($chip == 2 and ($reg & 0xfe) == 0xc0);
return 7;