Home | History | Annotate | Line # | Download | only in ep93xx
ep93xx_busdma.c revision 1.4
      1  1.4  dyoung /*	$NetBSD: ep93xx_busdma.c,v 1.4 2011/07/01 19:31:17 dyoung Exp $ */
      2  1.1    joff 
      3  1.1    joff /*
      4  1.1    joff  * Copyright (c) 2004 Jesse Off
      5  1.1    joff  * All rights reserved.
      6  1.1    joff  *
      7  1.1    joff  * Redistribution and use in source and binary forms, with or without
      8  1.1    joff  * modification, are permitted provided that the following conditions
      9  1.1    joff  * are met:
     10  1.1    joff  * 1. Redistributions of source code must retain the above copyright
     11  1.1    joff  *    notice, this list of conditions and the following disclaimer.
     12  1.1    joff  * 2. Redistributions in binary form must reproduce the above copyright
     13  1.1    joff  *    notice, this list of conditions and the following disclaimer in the
     14  1.1    joff  *    documentation and/or other materials provided with the distribution.
     15  1.1    joff  *
     16  1.1    joff  * THIS SOFTWARE IS PROVIDED BY FUJITSU COMPONENT LIMITED AND GENETEC
     17  1.1    joff  * CORPORATION ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
     18  1.1    joff  * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
     19  1.1    joff  * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
     20  1.1    joff  * DISCLAIMED.  IN NO EVENT SHALL FUJITSU COMPONENT LIMITED OR GENETEC
     21  1.1    joff  * CORPORATION BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
     22  1.1    joff  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
     23  1.1    joff  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
     24  1.1    joff  * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
     25  1.1    joff  * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
     26  1.1    joff  * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
     27  1.1    joff  * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
     28  1.1    joff  * SUCH DAMAGE.
     29  1.1    joff  */
     30  1.1    joff 
     31  1.1    joff /*
     32  1.1    joff  * bus_dma tag for EP93xx CPUs
     33  1.1    joff  */
     34  1.1    joff 
     35  1.1    joff #include <sys/cdefs.h>
     36  1.4  dyoung __KERNEL_RCSID(0, "$NetBSD: ep93xx_busdma.c,v 1.4 2011/07/01 19:31:17 dyoung Exp $");
     37  1.1    joff 
     38  1.1    joff #include <sys/param.h>
     39  1.1    joff #include <sys/types.h>
     40  1.1    joff #include <sys/device.h>
     41  1.1    joff #include <sys/systm.h>
     42  1.1    joff #include <sys/extent.h>
     43  1.1    joff 
     44  1.1    joff #define _ARM32_BUS_DMA_PRIVATE
     45  1.4  dyoung #include <sys/bus.h>
     46  1.1    joff 
     47  1.1    joff #include <arm/ep93xx/ep93xxvar.h>
     48  1.1    joff 
     49  1.1    joff struct arm32_bus_dma_tag ep93xx_bus_dma = {
     50  1.1    joff 	NULL,			/* _ranges: set by platform specific routine */
     51  1.1    joff 	0,			/* _nranges */
     52  1.1    joff 
     53  1.1    joff 	NULL,			/* _cookie */
     54  1.1    joff 
     55  1.1    joff 	_bus_dmamap_create,
     56  1.1    joff 	_bus_dmamap_destroy,
     57  1.1    joff 	_bus_dmamap_load,
     58  1.1    joff 	_bus_dmamap_load_mbuf,
     59  1.1    joff 	_bus_dmamap_load_uio,
     60  1.1    joff 	_bus_dmamap_load_raw,
     61  1.1    joff 	_bus_dmamap_unload,
     62  1.1    joff 	_bus_dmamap_sync,
     63  1.1    joff 	NULL,			/* sync_post */
     64  1.1    joff 
     65  1.1    joff 	_bus_dmamem_alloc,
     66  1.1    joff 	_bus_dmamem_free,
     67  1.1    joff 	_bus_dmamem_map,
     68  1.1    joff 	_bus_dmamem_unmap,
     69  1.1    joff 	_bus_dmamem_mmap,
     70  1.1    joff };
     71