summaryrefslogtreecommitdiff
path: root/sys/dev/i2c
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2007-09-05 03:11:33 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2007-09-05 03:11:33 +0000
commit9b03701e1a1e4521364c492d7ff5f8dab9672441 (patch)
treed3ba983b3934f9512eddc908f6eec06bdc4be79a /sys/dev/i2c
parented2c81c020cc88cbbf163e0b0ea1b6bca2fbf8cb (diff)
fix over-agressive match function, oops
Diffstat (limited to 'sys/dev/i2c')
-rw-r--r--sys/dev/i2c/lm93.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/sys/dev/i2c/lm93.c b/sys/dev/i2c/lm93.c
index 30e7d3da7a9..8bfa1902a6a 100644
--- a/sys/dev/i2c/lm93.c
+++ b/sys/dev/i2c/lm93.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: lm93.c,v 1.1 2007/09/04 20:19:22 deraadt Exp $ */
+/* $OpenBSD: lm93.c,v 1.2 2007/09/05 03:11:32 deraadt Exp $ */
/*
* Copyright (c) 2005 Mark Kettenis
@@ -157,7 +157,11 @@ struct cfdriver lmn_cd = {
int
lmn_match(struct device *parent, void *match, void *aux)
{
- return (1);
+ struct i2c_attach_args *ia = aux;
+
+ if (strcmp(ia->ia_name, "lm93") == 0)
+ return (1);
+ return (0);
}
void