summaryrefslogtreecommitdiff
path: root/sys/dev/pci/alipm.c
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2006-01-02 01:58:56 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2006-01-02 01:58:56 +0000
commitd45b66087c747ba180951d66880a5d908f5a109a (patch)
tree13d7f2d1cf3a6ad5eccd526e50cc6d1a0a6f0aba /sys/dev/pci/alipm.c
parent19c2190d65b50ccbcb1385e2ef74f7e2f1c6c92d (diff)
do i2c initialization using ofw data instead of scanning; ok kettenis
this may require some changes for non-pmu controllers later, which may do the ofw tables slightly differently
Diffstat (limited to 'sys/dev/pci/alipm.c')
-rw-r--r--sys/dev/pci/alipm.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/sys/dev/pci/alipm.c b/sys/dev/pci/alipm.c
index 4c7588a3156..a82ca8479a0 100644
--- a/sys/dev/pci/alipm.c
+++ b/sys/dev/pci/alipm.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: alipm.c,v 1.4 2006/01/01 20:52:26 deraadt Exp $ */
+/* $OpenBSD: alipm.c,v 1.5 2006/01/02 01:58:53 deraadt Exp $ */
/*
* Copyright (c) 2005 Mark Kettenis
@@ -29,6 +29,10 @@
#include <dev/pci/pcireg.h>
#include <dev/pci/pcivar.h>
+#ifdef __sparc64__
+#include <arch/sparc64/dev/ofwi2cvar.h>
+#endif
+
/*
* Acer Labs M7101 Power register definitions.
*/
@@ -215,6 +219,10 @@ alipm_attach(struct device *parent, struct device *self, void *aux)
bzero(&iba, sizeof iba);
iba.iba_name = "iic";
iba.iba_tag = &sc->sc_smb_tag;
+#ifdef __sparc64__
+ iba.iba_bus_scan = ofwiic_scan;
+ iba.iba_bus_scan_arg = pa;
+#endif
config_found(&sc->sc_dev, &iba, iicbus_print);
}