diff options
author | phk <phk@FreeBSD.org> | 2007-05-04 19:15:28 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 2007-05-04 19:15:28 +0000 |
commit | f0941ae8a011ae317ba818e20f8e612832d540ee (patch) | |
tree | c8218238455dfbb0b316d01494a39aab443e1db0 /sys/dev/gem/if_gemvar.h | |
parent | a717b2a83a783ddc654fe793a61273501c90abcb (diff) | |
download | FreeBSD-src-f0941ae8a011ae317ba818e20f8e612832d540ee.zip FreeBSD-src-f0941ae8a011ae317ba818e20f8e612832d540ee.tar.gz |
Since if_gem is being touted as one of our more architecturally
correct network drivers with respect to busmaster DMA, go over it
with at duster to make other aspects of it a role model:
Eliminate the pci specific softc, it serves no rational purpose.
Use convenience resource allocation/deallocation functions to save
code and errorhandling.
Switch from bus_space_{read|write}_%u() to bus_{read|write}_%u()
functions and forget about tags and handles, the resource will know
about those, should they be needed. This also eliminates a number
of inconsistently named local variables.
Diffstat (limited to 'sys/dev/gem/if_gemvar.h')
-rw-r--r-- | sys/dev/gem/if_gemvar.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/gem/if_gemvar.h b/sys/dev/gem/if_gemvar.h index 28ac061..80bf26f 100644 --- a/sys/dev/gem/if_gemvar.h +++ b/sys/dev/gem/if_gemvar.h @@ -133,13 +133,13 @@ struct gem_softc { int sc_wdog_timer; /* watchdog timer */ /* The following bus handles are to be provided by the bus front-end */ - bus_space_tag_t sc_bustag; /* bus tag */ + void *sc_ih; + struct resource *sc_res[2]; bus_dma_tag_t sc_pdmatag; /* parent bus dma tag */ bus_dma_tag_t sc_rdmatag; /* RX bus dma tag */ bus_dma_tag_t sc_tdmatag; /* TX bus dma tag */ bus_dma_tag_t sc_cdmatag; /* control data bus dma tag */ bus_dmamap_t sc_dmamap; /* bus dma handle */ - bus_space_handle_t sc_h; /* bus space handle for all regs */ int sc_phys[2]; /* MII instance -> PHY map */ |