From d49024b6f48c6368a3af0f695133bdc2a695e281 Mon Sep 17 00:00:00 2001 From: yongari Date: Thu, 19 Nov 2009 22:06:19 +0000 Subject: [PATCH] Use bus_{read,write}_4 rather than bus_space_{read,write}_4. --- sys/dev/et/if_et.c | 2 -- sys/dev/et/if_etvar.h | 6 ++---- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/sys/dev/et/if_et.c b/sys/dev/et/if_et.c index 0e11fd89a8c4..f9c4c27d1676 100644 --- a/sys/dev/et/if_et.c +++ b/sys/dev/et/if_et.c @@ -269,8 +269,6 @@ et_attach(device_t dev) device_printf(dev, "can't allocate IO memory\n"); return (ENXIO); } - sc->sc_mem_bt = rman_get_bustag(sc->sc_mem_res); - sc->sc_mem_bh = rman_get_bushandle(sc->sc_mem_res); msic = 0; if (pci_find_extcap(dev, PCIY_EXPRESS, &cap) == 0) { diff --git a/sys/dev/et/if_etvar.h b/sys/dev/et/if_etvar.h index 198d20cb28b1..10c0e50559f9 100644 --- a/sys/dev/et/if_etvar.h +++ b/sys/dev/et/if_etvar.h @@ -92,9 +92,9 @@ m_getl(int len, int how, int type, int flags, int *psize) #define ET_JUMBO_MEM_SIZE (ET_JSLOTS * ET_JLEN) #define CSR_WRITE_4(sc, reg, val) \ - bus_space_write_4((sc)->sc_mem_bt, (sc)->sc_mem_bh, (reg), (val)) + bus_write_4((sc)->sc_mem_res, (reg), (val)) #define CSR_READ_4(sc, reg) \ - bus_space_read_4((sc)->sc_mem_bt, (sc)->sc_mem_bh, (reg)) + bus_read_4((sc)->sc_mem_res, (reg)) #define ET_ADDR_HI(addr) ((uint64_t) (addr) >> 32) #define ET_ADDR_LO(addr) ((uint64_t) (addr) & 0xffffffff) @@ -229,8 +229,6 @@ struct et_softc { device_t dev; struct mtx sc_mtx; device_t sc_miibus; - bus_space_handle_t sc_mem_bh; - bus_space_tag_t sc_mem_bt; void *sc_irq_handle; struct resource *sc_irq_res; struct resource *sc_mem_res;