diff options
-rw-r--r-- | sys/arch/amd64/conf/files.amd64 | 4 | ||||
-rw-r--r-- | sys/arch/i386/conf/files.i386 | 4 | ||||
-rw-r--r-- | sys/conf/files | 6 | ||||
-rw-r--r-- | sys/dev/i2c/i2c.c | 11 | ||||
-rw-r--r-- | sys/dev/ipmi.c | 6 |
5 files changed, 22 insertions, 9 deletions
diff --git a/sys/arch/amd64/conf/files.amd64 b/sys/arch/amd64/conf/files.amd64 index ee7d41bfcaf..a037af47783 100644 --- a/sys/arch/amd64/conf/files.amd64 +++ b/sys/arch/amd64/conf/files.amd64 @@ -1,4 +1,4 @@ -# $OpenBSD: files.amd64,v 1.17 2005/12/29 14:45:11 kettenis Exp $ +# $OpenBSD: files.amd64,v 1.18 2006/01/29 17:29:29 marco Exp $ maxpartitions 16 maxusers 2 16 128 @@ -178,9 +178,7 @@ file arch/amd64/amd64/acpi_machdep.c acpi # # IPMI # -device ipmi attach ipmi at mainbus -file dev/ipmi.c ipmi needs-flag # # device major numbers diff --git a/sys/arch/i386/conf/files.i386 b/sys/arch/i386/conf/files.i386 index ab69807f0b5..15d54da0c37 100644 --- a/sys/arch/i386/conf/files.i386 +++ b/sys/arch/i386/conf/files.i386 @@ -1,4 +1,4 @@ -# $OpenBSD: files.i386,v 1.141 2005/11/21 17:24:26 jordan Exp $ +# $OpenBSD: files.i386,v 1.142 2006/01/29 17:29:29 marco Exp $ # # new style config file for i386 architecture # @@ -403,9 +403,7 @@ file arch/i386/i386/acpi_machdep.c acpi # # IPMI # -device ipmi attach ipmi at mainbus -file dev/ipmi.c ipmi needs-flag # Dell Embedded Systems Management device esm diff --git a/sys/conf/files b/sys/conf/files index 434cc418df3..9e3229ad325 100644 --- a/sys/conf/files +++ b/sys/conf/files @@ -1,4 +1,4 @@ -# $OpenBSD: files,v 1.363 2006/01/23 14:42:54 martin Exp $ +# $OpenBSD: files,v 1.364 2006/01/29 17:29:29 marco Exp $ # $NetBSD: files,v 1.87 1996/05/19 17:17:50 jonathan Exp $ # @(#)files.newconf 7.5 (Berkeley) 5/10/93 @@ -389,6 +389,10 @@ device radio attach radio at radiobus file dev/radio.c radio needs-flag +# IPMI +device ipmi +file dev/ipmi.c ipmi needs-flag + # legitimate pseudo-devices pseudo-device vnd: disk pseudo-device ccd: disk diff --git a/sys/dev/i2c/i2c.c b/sys/dev/i2c/i2c.c index d6549ae1f33..90efd50f0f6 100644 --- a/sys/dev/i2c/i2c.c +++ b/sys/dev/i2c/i2c.c @@ -1,4 +1,4 @@ -/* $OpenBSD: i2c.c,v 1.11 2006/01/01 20:52:25 deraadt Exp $ */ +/* $OpenBSD: i2c.c,v 1.12 2006/01/29 17:29:30 marco Exp $ */ /* $NetBSD: i2c.c,v 1.1 2003/09/30 00:35:31 thorpej Exp $ */ /* @@ -48,6 +48,8 @@ #define IICCF_ADDR 0 #define IICCF_SIZE 1 +#include "ipmi.h" + struct iic_softc { struct device sc_dev; i2c_tag_t sc_tag; @@ -115,6 +117,13 @@ iic_match(struct device *parent, void *arg, void *aux) struct cfdata *cf = arg; struct i2cbus_attach_args *iba = aux; +#if NIPMI > 0 + extern int ipmi_enabled; + + if (ipmi_enabled) + return (0); +#endif + /* Just make sure we're looking for i2c. */ return (strcmp(iba->iba_name, cf->cf_driver->cd_name) == 0); } diff --git a/sys/dev/ipmi.c b/sys/dev/ipmi.c index f82fdd3d3c5..fc5dc6ba467 100644 --- a/sys/dev/ipmi.c +++ b/sys/dev/ipmi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ipmi.c,v 1.33 2006/01/19 17:08:39 grange Exp $ */ +/* $OpenBSD: ipmi.c,v 1.34 2006/01/29 17:29:29 marco Exp $ */ /* * Copyright (c) 2005 Jordan Hargrave @@ -59,6 +59,7 @@ struct ipmi_sensor { int ipmi_nintr; int ipmi_dbg = 0; int ipmi_poll = 1; +int ipmi_enabled = 0; #define SENSOR_REFRESH_RATE (10 * hz) @@ -1750,6 +1751,9 @@ ipmi_attach(struct device *parent, struct device *self, void *aux) printf(" irq %d", ia->iaa_if_irq); printf("\n"); + /* setup flag to exclude iic */ + ipmi_enabled = 1; + /* Setup Watchdog timer */ sc->sc_wdog_period = 0; wdog_register(sc, ipmi_watchdog); |