Cast to make up for the difference in type between our bus_dma_map(9) and
theirs. Where we expect kvap to be of void **, they expect caddr_t (typedef char *).
This commit is contained in:
parent
657257e0c1
commit
322778c4e2
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: if_rge.c,v 1.7 2020/02/27 22:58:57 sevan Exp $ */
|
||||
/* $NetBSD: if_rge.c,v 1.8 2020/02/27 23:15:34 sevan Exp $ */
|
||||
/* $OpenBSD: if_rge.c,v 1.2 2020/01/02 09:00:45 kevlo Exp $ */
|
||||
|
||||
/*
|
||||
@ -18,7 +18,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: if_rge.c,v 1.7 2020/02/27 22:58:57 sevan Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: if_rge.c,v 1.8 2020/02/27 23:15:34 sevan Exp $");
|
||||
|
||||
/* #include "vlan.h" Sevan */
|
||||
|
||||
@ -968,7 +968,7 @@ rge_allocmem(struct rge_softc *sc)
|
||||
/* Load the map for the TX ring. */
|
||||
error = bus_dmamem_map(sc->sc_dmat, &sc->rge_ldata.rge_tx_listseg,
|
||||
sc->rge_ldata.rge_tx_listnseg, RGE_TX_LIST_SZ,
|
||||
&sc->rge_ldata.rge_tx_list,
|
||||
(void **) &sc->rge_ldata.rge_tx_list,
|
||||
BUS_DMA_NOWAIT); /* XXX OpenBSD adds BUS_DMA_COHERENT */
|
||||
if (error) {
|
||||
printf("%s: can't map TX dma buffers\n", sc->sc_dev.dv_xname);
|
||||
@ -1018,7 +1018,7 @@ rge_allocmem(struct rge_softc *sc)
|
||||
/* Load the map for the RX ring. */
|
||||
error = bus_dmamem_map(sc->sc_dmat, &sc->rge_ldata.rge_rx_listseg,
|
||||
sc->rge_ldata.rge_rx_listnseg, RGE_RX_LIST_SZ,
|
||||
&sc->rge_ldata.rge_rx_list,
|
||||
(void **) &sc->rge_ldata.rge_rx_list,
|
||||
BUS_DMA_NOWAIT); /* XXX OpenBSD adds BUS_DMA_COHERENT */
|
||||
if (error) {
|
||||
printf("%s: can't map RX dma buffers\n", sc->sc_dev.dv_xname);
|
||||
|
Loading…
Reference in New Issue
Block a user