convert alpha vtophys() #defines to use __alpha_bus_XXX_dmamap(), to

get rid of the nasty (vtophys(va) | 0x40000000) expressions, and to make
the code more correct.
This commit is contained in:
cgd 1996-06-03 20:30:21 +00:00
parent c6dd609e7f
commit b1b4f705ba
3 changed files with 12 additions and 10 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: if_de.c,v 1.22 1996/05/13 00:03:09 mycroft Exp $ */
/* $NetBSD: if_de.c,v 1.23 1996/06/03 20:30:21 cgd Exp $ */
/*-
* Copyright (c) 1994, 1995 Matt Thomas (matt@lkg.dec.com)
@ -424,7 +424,8 @@ static void tulip_addr_filter(tulip_softc_t *sc);
#if defined(__NetBSD__) && defined(__alpha__)
/* XXX XXX NEED REAL DMA MAPPING SUPPORT XXX XXX */
#define vtophys(va) (vtophys(va) | 0x40000000)
#define vtophys(va) __alpha_bus_XXX_dmamap(sc->tulip_bc, (void *)(va))
#endif
static int

View File

@ -1,4 +1,4 @@
/* $NetBSD: if_le_pci.c,v 1.6 1996/05/14 22:23:38 thorpej Exp $ */
/* $NetBSD: if_le_pci.c,v 1.7 1996/06/03 20:30:29 cgd Exp $ */
/*-
* Copyright (c) 1995 Charles M. Hannum. All rights reserved.
@ -76,7 +76,7 @@
#ifdef __alpha__ /* XXX */
/* XXX XXX NEED REAL DMA MAPPING SUPPORT XXX XXX */
#define vtophys(va) (vtophys(va) | 0x40000000)
#define vtophys(va) __alpha_bus_XXX_dmamap(lesc->sc_bc, (void *)(va))
#endif
int le_pci_match __P((struct device *, void *, void *));

View File

@ -1,4 +1,4 @@
/* $NetBSD: ncr.c,v 1.35 1996/05/13 00:03:26 mycroft Exp $ */
/* $NetBSD: ncr.c,v 1.36 1996/06/03 20:30:34 cgd Exp $ */
/**************************************************************************
**
@ -211,7 +211,7 @@ extern PRINT_ADDR();
#if defined(__NetBSD__) && defined(__alpha__)
/* XXX XXX NEED REAL DMA MAPPING SUPPORT XXX XXX */
#define vtophys(va) (vtophys(va) | 0x40000000)
#define vtophys(va) __alpha_bus_XXX_dmamap(np->sc_bc, (void *)(va))
#endif
/*==========================================================
@ -1294,7 +1294,8 @@ static void ncb_profile (ncb_p np, ccb_p cp);
static void ncr_script_copy_and_bind
(struct script * script, ncb_p np);
static void ncr_script_fill (struct script * scr);
static int ncr_scatter (struct dsb* phys,u_long vaddr,u_long datalen);
static int ncr_scatter (ncb_p np, struct dsb* phys,u_long vaddr,
u_long datalen);
static void ncr_setmaxtags (tcb_p tp, u_long usrtags);
static void ncr_setsync (ncb_p np, ccb_p cp, u_char sxfer);
static void ncr_settags (tcb_p tp, lcb_p lp);
@ -1328,7 +1329,7 @@ static void ncr_attach (pcici_t tag, int unit);
#if 0
static char ident[] =
"\n$NetBSD: ncr.c,v 1.35 1996/05/13 00:03:26 mycroft Exp $\n";
"\n$NetBSD: ncr.c,v 1.36 1996/06/03 20:30:34 cgd Exp $\n";
#endif
u_long ncr_version = NCR_VERSION * 11
@ -4043,7 +4044,7 @@ static INT32 ncr_start (struct scsi_xfer * xp)
**----------------------------------------------------
*/
segments = ncr_scatter (&cp->phys, (vm_offset_t) xp->data,
segments = ncr_scatter (np, &cp->phys, (vm_offset_t) xp->data,
(vm_size_t) xp->datalen);
if (segments < 0) {
@ -6601,7 +6602,7 @@ static void ncr_opennings (ncb_p np, lcb_p lp, struct scsi_xfer * xp)
*/
static int ncr_scatter
(struct dsb* phys, vm_offset_t vaddr, vm_size_t datalen)
(ncb_p np, struct dsb* phys, vm_offset_t vaddr, vm_size_t datalen)
{
u_long paddr, pnext;