2 #ifndef _PPC_SCATTERLIST_H
3 #define _PPC_SCATTERLIST_H
8 char *address; /* Location data is to be transferred to,
9 * or NULL for highmem page */
10 struct page * page; /* Location for highmem page, if any */
11 unsigned int offset; /* for highmem, page offset */
12 unsigned int length; /* length at address or page+offset */
14 dma_addr_t dma_address; /* phys/bus dma address */
15 unsigned int dma_length; /* number of bytes mapped at dma_address */
16 /* Note that if we coalesce multiple scatterlist elements,
17 dma_length can be different from length */
21 * These macros should be used after a pci_map_sg call has been done
22 * to get bus addresses of each of the SG entries and their lengths.
23 * You should only work with the number of sg entries pci_map_sg
24 * returns, or alternatively stop on the first sg_dma_len(sg) which
27 #define sg_dma_address(sg) ((sg)->dma_address)
28 #define sg_dma_len(sg) ((sg)->dma_length)
30 #endif /* !(_PPC_SCATTERLIST_H) */
31 #endif /* __KERNEL__ */