psycho.c (115316) | psycho.c (115343) |
---|---|
1/* 2 * Copyright (c) 1999, 2000 Matthew R. Green 3 * All rights reserved. 4 * Copyright 2001 by Thomas Moestl <tmm@FreeBSD.org>. All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 14 unchanged lines hidden (view full) --- 23 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 24 * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 25 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 * SUCH DAMAGE. 28 * 29 * from: NetBSD: psycho.c,v 1.39 2001/10/07 20:30:41 eeh Exp 30 * | 1/* 2 * Copyright (c) 1999, 2000 Matthew R. Green 3 * All rights reserved. 4 * Copyright 2001 by Thomas Moestl <tmm@FreeBSD.org>. All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 14 unchanged lines hidden (view full) --- 23 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 24 * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 25 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 * SUCH DAMAGE. 28 * 29 * from: NetBSD: psycho.c,v 1.39 2001/10/07 20:30:41 eeh Exp 30 * |
31 * $FreeBSD: head/sys/sparc64/pci/psycho.c 115316 2003-05-26 04:00:52Z scottl $ | 31 * $FreeBSD: head/sys/sparc64/pci/psycho.c 115343 2003-05-27 04:59:59Z scottl $ |
32 */ 33 34/* 35 * Support for `psycho' and `psycho+' UPA to PCI bridge and 36 * UltraSPARC IIi and IIe `sabre' PCI controllers. 37 */ 38 39#include "opt_psycho.h" --- 66 unchanged lines hidden (view full) --- 106static int psycho_dmamap_destroy(bus_dma_tag_t, bus_dma_tag_t, bus_dmamap_t); 107static int psycho_dmamap_load(bus_dma_tag_t, bus_dma_tag_t, bus_dmamap_t, 108 void *, bus_size_t, bus_dmamap_callback_t *, void *, int); 109static int psycho_dmamap_load_mbuf(bus_dma_tag_t, bus_dma_tag_t, bus_dmamap_t, 110 struct mbuf *, bus_dmamap_callback2_t *, void *, int); 111static int psycho_dmamap_load_uio(bus_dma_tag_t, bus_dma_tag_t, bus_dmamap_t, 112 struct uio *, bus_dmamap_callback2_t *, void *, int); 113static void psycho_dmamap_unload(bus_dma_tag_t, bus_dma_tag_t, bus_dmamap_t); | 32 */ 33 34/* 35 * Support for `psycho' and `psycho+' UPA to PCI bridge and 36 * UltraSPARC IIi and IIe `sabre' PCI controllers. 37 */ 38 39#include "opt_psycho.h" --- 66 unchanged lines hidden (view full) --- 106static int psycho_dmamap_destroy(bus_dma_tag_t, bus_dma_tag_t, bus_dmamap_t); 107static int psycho_dmamap_load(bus_dma_tag_t, bus_dma_tag_t, bus_dmamap_t, 108 void *, bus_size_t, bus_dmamap_callback_t *, void *, int); 109static int psycho_dmamap_load_mbuf(bus_dma_tag_t, bus_dma_tag_t, bus_dmamap_t, 110 struct mbuf *, bus_dmamap_callback2_t *, void *, int); 111static int psycho_dmamap_load_uio(bus_dma_tag_t, bus_dma_tag_t, bus_dmamap_t, 112 struct uio *, bus_dmamap_callback2_t *, void *, int); 113static void psycho_dmamap_unload(bus_dma_tag_t, bus_dma_tag_t, bus_dmamap_t); |
114static void psycho_dmamap_sync(bus_dma_tag_t, bus_dma_tag_t, bus_dmamap_t, int); | 114static void psycho_dmamap_sync(bus_dma_tag_t, bus_dma_tag_t, bus_dmamap_t, 115 bus_dmasync_op_t); |
115static int psycho_dmamem_alloc(bus_dma_tag_t, bus_dma_tag_t, void **, int, 116 bus_dmamap_t *); 117static void psycho_dmamem_free(bus_dma_tag_t, bus_dma_tag_t, void *, 118 bus_dmamap_t); 119 120/* 121 * autoconfiguration 122 */ --- 1274 unchanged lines hidden (view full) --- 1397 struct psycho_softc *sc; 1398 1399 sc = (struct psycho_softc *)pdmat->dt_cookie; 1400 iommu_dvmamap_unload(pdmat, ddmat, sc->sc_is, map); 1401} 1402 1403static void 1404psycho_dmamap_sync(bus_dma_tag_t pdmat, bus_dma_tag_t ddmat, bus_dmamap_t map, | 116static int psycho_dmamem_alloc(bus_dma_tag_t, bus_dma_tag_t, void **, int, 117 bus_dmamap_t *); 118static void psycho_dmamem_free(bus_dma_tag_t, bus_dma_tag_t, void *, 119 bus_dmamap_t); 120 121/* 122 * autoconfiguration 123 */ --- 1274 unchanged lines hidden (view full) --- 1398 struct psycho_softc *sc; 1399 1400 sc = (struct psycho_softc *)pdmat->dt_cookie; 1401 iommu_dvmamap_unload(pdmat, ddmat, sc->sc_is, map); 1402} 1403 1404static void 1405psycho_dmamap_sync(bus_dma_tag_t pdmat, bus_dma_tag_t ddmat, bus_dmamap_t map, |
1405 int op) | 1406 bus_dmasync_op_t op) |
1406{ 1407 struct psycho_softc *sc; 1408 1409 sc = (struct psycho_softc *)pdmat->dt_cookie; 1410 iommu_dvmamap_sync(pdmat, ddmat, sc->sc_is, map, op); 1411} | 1407{ 1408 struct psycho_softc *sc; 1409 1410 sc = (struct psycho_softc *)pdmat->dt_cookie; 1411 iommu_dvmamap_sync(pdmat, ddmat, sc->sc_is, map, op); 1412} |