blob: 62269b31ebf4a89d404ec157cd653cba848de2f7 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001#ifndef _ASM_PARISC_SCATTERLIST_H
2#define _ASM_PARISC_SCATTERLIST_H
3
4#include <asm/page.h>
Jean Delvarea9dfd282007-03-06 02:45:12 -08005#include <asm/types.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -07006
7struct scatterlist {
Jens Axboed6ec0842007-10-22 20:01:06 +02008#ifdef CONFIG_DEBUG_SG
9 unsigned long sg_magic;
10#endif
Jens Axboe18dabf42007-10-22 19:57:20 +020011 unsigned long page_link;
Linus Torvalds1da177e2005-04-16 15:20:36 -070012 unsigned int offset;
13
14 unsigned int length;
15
16 /* an IOVA can be 64-bits on some PA-Risc platforms. */
17 dma_addr_t iova; /* I/O Virtual Address */
18 __u32 iova_length; /* bytes mapped */
19};
20
FUJITA Tomonorib61e8f42007-10-23 09:30:28 +020021#define sg_virt_addr(sg) ((unsigned long)sg_virt(sg))
Linus Torvalds1da177e2005-04-16 15:20:36 -070022#define sg_dma_address(sg) ((sg)->iova)
23#define sg_dma_len(sg) ((sg)->iova_length)
24
25#define ISA_DMA_THRESHOLD (~0UL)
26
27#endif /* _ASM_PARISC_SCATTERLIST_H */