From 9b03701e1a1e4521364c492d7ff5f8dab9672441 Mon Sep 17 00:00:00 2001 From: Theo de Raadt Date: Wed, 5 Sep 2007 03:11:33 +0000 Subject: fix over-agressive match function, oops --- sys/dev/i2c/lm93.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'sys/dev/i2c') 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 -- cgit v1.2.3