summaryrefslogtreecommitdiffstats
path: root/sys/dev/i2c
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2008-04-09 21:56:40 +0000
committerderaadt <deraadt@openbsd.org>2008-04-09 21:56:40 +0000
commit41f577e10d0d687ad87781ab11c94292c00176a2 (patch)
tree725b94651f72d287b4a9f40d9eb0f45be21802ce /sys/dev/i2c
parentOn sparc64, a zero base address doesn't mean the BAR is invalid. We probably (diff)
downloadwireguard-openbsd-41f577e10d0d687ad87781ab11c94292c00176a2.tar.xz
wireguard-openbsd-41f577e10d0d687ad87781ab11c94292c00176a2.zip
support the NPX SE97 too
Diffstat (limited to 'sys/dev/i2c')
-rw-r--r--sys/dev/i2c/i2c_scan.c6
-rw-r--r--sys/dev/i2c/sdtemp.c5
2 files changed, 8 insertions, 3 deletions
diff --git a/sys/dev/i2c/i2c_scan.c b/sys/dev/i2c/i2c_scan.c
index 3c5368abaa1..c424056d373 100644
--- a/sys/dev/i2c/i2c_scan.c
+++ b/sys/dev/i2c/i2c_scan.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: i2c_scan.c,v 1.118 2008/04/07 00:31:07 deraadt Exp $ */
+/* $OpenBSD: i2c_scan.c,v 1.119 2008/04/09 21:56:40 deraadt Exp $ */
/*
* Copyright (c) 2005 Theo de Raadt <deraadt@openbsd.org>
@@ -851,6 +851,10 @@ iic_probe_sensor(struct device *self, u_int8_t addr)
iicprobew(0x07) == 0xa101 &&
(iicprobew(0x00) & 0xfff0) == 0x0010) {
name = "se98";
+ } else if ((addr & 0x18) == 0x18 && iicprobew(0x06) == 0x1131 &&
+ iicprobew(0x07) == 0xa200 &&
+ (iicprobew(0x00) & 0xfff0) == 0x0010) {
+ name = "se97";
} else if ((addr & 0x18) == 0x18 && iicprobew(0x06) == 0x11d4 &&
(iicprobew(0x07) & 0xfff0) == 0x0800 &&
iicprobew(0x00) == 0x001d) {
diff --git a/sys/dev/i2c/sdtemp.c b/sys/dev/i2c/sdtemp.c
index 4ba1d3d1a9c..4b0a998d996 100644
--- a/sys/dev/i2c/sdtemp.c
+++ b/sys/dev/i2c/sdtemp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sdtemp.c,v 1.1 2008/04/07 01:31:44 deraadt Exp $ */
+/* $OpenBSD: sdtemp.c,v 1.2 2008/04/09 21:56:40 deraadt Exp $ */
/*
* Copyright (c) 2008 Theo de Raadt
@@ -57,7 +57,8 @@ sdtemp_match(struct device *parent, void *match, void *aux)
{
struct i2c_attach_args *ia = aux;
- if (strcmp(ia->ia_name, "se98") == 0 ||
+ if (strcmp(ia->ia_name, "se97") == 0 ||
+ strcmp(ia->ia_name, "se98") == 0 ||
strcmp(ia->ia_name, "adt7408") == 0)
return (1);
return (0);