Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Functions
dma-mapping.h File Reference
#include <asm/cache.h>

Go to the source code of this file.

Functions

voiddma_alloc_coherent (struct device *, size_t, dma_addr_t *, gfp_t)
 
void dma_free_coherent (struct device *, size_t, void *, dma_addr_t)
 
dma_addr_t dma_map_single (struct device *, void *, size_t, enum dma_data_direction)
 
dma_addr_t dma_map_page (struct device *, struct page *, unsigned long, size_t size, enum dma_data_direction)
 
int dma_map_sg (struct device *, struct scatterlist *, int, enum dma_data_direction)
 
void dma_sync_single_for_device (struct device *, dma_addr_t, size_t, enum dma_data_direction)
 
void dma_sync_sg_for_device (struct device *, struct scatterlist *, int, enum dma_data_direction)
 

Function Documentation

void* dma_alloc_coherent ( struct device ,
size_t  ,
dma_addr_t ,
gfp_t   
)

dma_alloc_coherent - allocate consistent memory for DMA : valid struct device pointer, or NULL for ISA and EISA-like devices : required memory size : bus-specific DMA address

Allocate some uncached, unbuffered memory for a device for performing DMA. This function allocates pages, and will return the CPU-viewed address, and sets to be the device-viewed address.

Definition at line 96 of file dma-coherent.c.

void dma_free_coherent ( struct device ,
size_t  ,
void ,
dma_addr_t   
)

dma_free_coherent - free memory allocated by dma_alloc_coherent : valid struct device pointer, or NULL for ISA and EISA-like devices : size of memory originally requested in dma_alloc_coherent : CPU-view address returned from dma_alloc_coherent : device-view address returned from dma_alloc_coherent

Free (and unmap) a DMA buffer previously allocated by dma_alloc_coherent().

References to memory and mappings associated with cpu_addr/handle during and after this call executing are illegal.

Definition at line 110 of file dma-coherent.c.

dma_addr_t dma_map_page ( struct device ,
struct page ,
unsigned  long,
size_t  size,
enum  dma_data_direction 
)

Definition at line 138 of file pci-dma-nommu.c.

int dma_map_sg ( struct device ,
struct scatterlist ,
int  ,
enum  dma_data_direction 
)

Definition at line 125 of file dma-mapping.c.

dma_addr_t dma_map_single ( struct device ,
void ,
size_t  ,
enum  dma_data_direction 
)

Definition at line 39 of file dma.c.

void dma_sync_sg_for_device ( struct device ,
struct scatterlist ,
int  ,
enum  dma_data_direction 
)

Definition at line 140 of file dma-mapping.c.

void dma_sync_single_for_device ( struct device ,
dma_addr_t  ,
size_t  ,
enum  dma_data_direction 
)

Definition at line 104 of file dma.c.