diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2006-07-15 19:39:57 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2006-07-15 19:39:57 +0000 |
commit | 69948c91bd82f2bf316a1c047103e6050887fe13 (patch) | |
tree | 62c12c38b4c041ada7d4efd2f979534c655b7f8f /sys/dev/i2c/i2c_scan.c | |
parent | 7282105c96d81f6684bf9171c0ebe40857d82be5 (diff) |
Add support for Genesys Logic GL523SM and Global Mixed-mode Technology G781.
tested by fgs@ and Stuart Henderson.
Diffstat (limited to 'sys/dev/i2c/i2c_scan.c')
-rw-r--r-- | sys/dev/i2c/i2c_scan.c | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/sys/dev/i2c/i2c_scan.c b/sys/dev/i2c/i2c_scan.c index 394e8b62678..48464ca9bf0 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.86 2006/07/12 15:35:40 deraadt Exp $ */ +/* $OpenBSD: i2c_scan.c,v 1.87 2006/07/15 19:39:56 kettenis Exp $ */ /* * Copyright (c) 2005 Theo de Raadt <deraadt@openbsd.org> @@ -497,6 +497,17 @@ iic_probe(struct device *self, struct i2cbus_attach_args *iba, u_int8_t addr) iicprobe(0x04) <= 0x09 && (iicprobe(0xbf) & 0xf8) == 0) name = "lm90"; break; + case 0x23: /* Genesys Logic? */ + if ((addr == 0x4c) && + (iicprobe(0x03) & 0x3f) == 0x00 && iicprobe(0x04) <= 0x08) + /* + * Genesys Logic doesn't make the datasheet + * for the GL523SM publically available, so + * the checks above are nothing more than a + * (conservative) educated guess. + */ + name = "gl523sm"; + break; case 0x41: /* Analog Devices */ if ((addr == 0x4c || addr == 0x4d) && iicprobe(0xff) == 0x51 && @@ -527,6 +538,14 @@ iic_probe(struct device *self, struct i2cbus_attach_args *iba, u_int8_t addr) skip_fc = 1; } break; + case 0x47: /* Global Mixed-mode Technology */ + if (addr == 0x4c && iicprobe(0xff) == 0x01 && + (iicprobe(0x03) & 0x3f) == 0x00 && iicprobe(0x04) <= 0x08) + name = "g781"; + if (addr == 0x4d && iicprobe(0xff) == 0x03 && + (iicprobe(0x03) & 0x3f) == 0x00 && iicprobe(0x04) <= 0x08) + name = "g781-1"; + break; case 0x4d: /* Maxim */ if ((addr == 0x18 || addr == 0x19 || addr == 0x1a || addr == 0x29 || addr == 0x2a || addr == 0x2b || |