Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/sparc/dev Switch to shared EBus headers in dev/ebus.
details: https://anonhg.NetBSD.org/src/rev/872ee94c7154
branches: trunk
changeset: 522387:872ee94c7154
user: uwe <uwe%NetBSD.org@localhost>
date: Mon Feb 18 04:52:26 2002 +0000
description:
Switch to shared EBus headers in dev/ebus.
diffstat:
sys/arch/sparc/dev/com_ebus.c | 13 +++++--------
sys/arch/sparc/dev/pckbc_js.c | 8 ++++----
sys/arch/sparc/dev/rtc.c | 13 +++++--------
3 files changed, 14 insertions(+), 20 deletions(-)
diffs (97 lines):
diff -r 61a6a36ae837 -r 872ee94c7154 sys/arch/sparc/dev/com_ebus.c
--- a/sys/arch/sparc/dev/com_ebus.c Mon Feb 18 04:50:57 2002 +0000
+++ b/sys/arch/sparc/dev/com_ebus.c Mon Feb 18 04:52:26 2002 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: com_ebus.c,v 1.1 2001/12/11 00:31:08 uwe Exp $ */
+/* $NetBSD: com_ebus.c,v 1.2 2002/02/18 04:52:26 uwe Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -47,8 +47,8 @@
#include <dev/pci/pcireg.h> /* XXX: for PCI_INTERRUPT_PIN */
-#include <sparc/dev/ebusreg.h>
-#include <sparc/dev/ebusvar.h>
+#include <dev/ebus/ebusreg.h>
+#include <dev/ebus/ebusvar.h>
#include <dev/ic/ns16550reg.h>
#include <dev/ic/comreg.h>
@@ -81,11 +81,8 @@
return (0);
match = 0;
- if (ebus_bus_map(ea->ea_bustag,
- EBUS_ADDR_FROM_REG(&ea->ea_reg[0]),
- ea->ea_reg[0].size,
- BUS_SPACE_MAP_LINEAR, 0,
- &ioh) == 0)
+ if (ebus_bus_map(ea->ea_bustag, EBUS_ADDR_FROM_REG(&ea->ea_reg[0]),
+ ea->ea_reg[0].size, 0, 0, &ioh) == 0)
{
match = comprobe1(ea->ea_bustag, ioh);
bus_space_unmap(ea->ea_bustag, ioh, ea->ea_reg[0].size);
diff -r 61a6a36ae837 -r 872ee94c7154 sys/arch/sparc/dev/pckbc_js.c
--- a/sys/arch/sparc/dev/pckbc_js.c Mon Feb 18 04:50:57 2002 +0000
+++ b/sys/arch/sparc/dev/pckbc_js.c Mon Feb 18 04:52:26 2002 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pckbc_js.c,v 1.1 2002/01/31 17:34:51 uwe Exp $ */
+/* $NetBSD: pckbc_js.c,v 1.2 2002/02/18 04:52:27 uwe Exp $ */
/*
* Copyright (c) 2002 Valeriy E. Ushakov
@@ -41,8 +41,8 @@
#include <dev/ic/pckbcvar.h>
#include <dev/pckbc/pckbdvar.h>
-#include <sparc/dev/ebusreg.h>
-#include <sparc/dev/ebusvar.h>
+#include <dev/ebus/ebusreg.h>
+#include <dev/ebus/ebusvar.h>
struct pckbc_js_softc {
@@ -142,7 +142,7 @@
int intr, isconsole;
iot = ea->ea_bustag;
- ioaddr = BUS_ADDR(ea->ea_reg[0].bar, ea->ea_reg[0].offset);
+ ioaddr = EBUS_ADDR_FROM_REG(&ea->ea_reg[0]);
intr = ea->ea_nintr ? ea->ea_intr[0] : /* line */ 0;
/* TODO: see comment in pckbc_obio_attach above */
diff -r 61a6a36ae837 -r 872ee94c7154 sys/arch/sparc/dev/rtc.c
--- a/sys/arch/sparc/dev/rtc.c Mon Feb 18 04:50:57 2002 +0000
+++ b/sys/arch/sparc/dev/rtc.c Mon Feb 18 04:52:26 2002 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: rtc.c,v 1.1 2001/12/11 00:29:21 uwe Exp $ */
+/* $NetBSD: rtc.c,v 1.2 2002/02/18 04:52:26 uwe Exp $ */
/*
* Copyright (c) 2001 Valeriy E. Ushakov
@@ -48,8 +48,8 @@
#include <dev/clock_subr.h>
#include <dev/ic/mc146818reg.h>
-#include <sparc/dev/ebusreg.h>
-#include <sparc/dev/ebusvar.h>
+#include <dev/ebus/ebusreg.h>
+#include <dev/ebus/ebusvar.h>
struct rtc_ebus_softc {
struct device sc_dev;
@@ -131,11 +131,8 @@
todr_chip_handle_t handle;
sc->sc_bt = ea->ea_bustag;
- if (ebus_bus_map(sc->sc_bt,
- BUS_ADDR(ea->ea_reg[0].bar, ea->ea_reg[0].offset),
- ea->ea_reg[0].size,
- BUS_SPACE_MAP_LINEAR, 0,
- &sc->sc_bh) != 0)
+ if (ebus_bus_map(sc->sc_bt, EBUS_ADDR_FROM_REG(&ea->ea_reg[0]),
+ ea->ea_reg[0].size, 0, 0, &sc->sc_bh) != 0)
{
printf(": can't map registers\n", self->dv_xname);
return;
Home |
Main Index |
Thread Index |
Old Index