Fix syncing of consumer block.
This commit is contained in:
parent
3dc4f22908
commit
5fb5017c94
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: pdq_ifsubr.c,v 1.15 1998/05/24 22:37:23 matt Exp $ */
|
||||
/* $NetBSD: pdq_ifsubr.c,v 1.16 1998/05/27 01:17:53 matt Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1995, 1996 Matt Thomas <matt@3am-software.com>
|
||||
@ -713,6 +713,14 @@ pdq_os_descriptor_block_sync(
|
||||
bus_dmamap_sync(sc->sc_dmatag, sc->sc_dbmap, offset, length, ops);
|
||||
}
|
||||
|
||||
extern void
|
||||
pdq_os_consumer_block_sync(
|
||||
pdq_os_ctx_t *sc,
|
||||
int ops)
|
||||
{
|
||||
bus_dmamap_sync(sc->sc_dmatag, sc->sc_cbmap, 0, sizeof(pdq_consumer_block_t), ops);
|
||||
}
|
||||
|
||||
extern void
|
||||
pdq_os_unsolicited_event_sync(
|
||||
pdq_os_ctx_t *sc,
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: pdqvar.h,v 1.20 1998/05/25 21:24:21 matt Exp $ */
|
||||
/* $NetBSD: pdqvar.h,v 1.21 1998/05/27 01:17:53 matt Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1995, 1996 Matt Thomas <matt@3am-software.com>
|
||||
@ -185,10 +185,10 @@ typedef bus_addr_t pdq_bus_memoffset_t;
|
||||
(u_int8_t *) (what) - (u_int8_t *) (pdq)->pdq_dbp, \
|
||||
(length), (why))
|
||||
#define PDQ_OS_CONSUMER_PRESYNC(pdq) \
|
||||
PDQ_OS_DESCBLOCK_SYNC((pdq), (pdq)->pdq_cbp, sizeof((pdq)->pdq_cbp), \
|
||||
pdq_os_consumer_block_sync((pdq)->pdq_os_ctx, \
|
||||
BUS_DMASYNC_PREREAD|BUS_DMASYNC_PREWRITE)
|
||||
#define PDQ_OS_CONSUMER_POSTSYNC(pdq) \
|
||||
PDQ_OS_DESCBLOCK_SYNC((pdq), (pdq)->pdq_cbp, sizeof((pdq)->pdq_cbp), \
|
||||
pdq_os_consumer_block_sync((pdq)->pdq_os_ctx, \
|
||||
BUS_DMASYNC_POSTREAD|BUS_DMASYNC_POSTWRITE)
|
||||
#define PDQ_OS_DESC_PRESYNC(pdq, d, s) \
|
||||
PDQ_OS_DESCBLOCK_SYNC((pdq), (d), (s), BUS_DMASYNC_PREWRITE)
|
||||
@ -222,6 +222,7 @@ typedef bus_addr_t pdq_bus_memoffset_t;
|
||||
struct _pdq_os_ctx_t;
|
||||
extern void pdq_os_descriptor_block_sync(struct _pdq_os_ctx_t *osctx, size_t offset,
|
||||
size_t length, int ops);
|
||||
extern void pdq_os_consumer_block_sync(struct _pdq_os_ctx_t *osctx, int ops);
|
||||
extern void pdq_os_unsolicited_event_sync(struct _pdq_os_ctx_t *osctx, size_t offset,
|
||||
size_t length, int ops);
|
||||
extern struct mbuf *pdq_os_databuf_alloc(struct _pdq_os_ctx_t *osctx);
|
||||
|
Loading…
Reference in New Issue
Block a user