- Update to 2.6.25-rc3.
[linux-flexiantxendom0-3.2.10.git] / include / asm-frv / scatterlist.h
index 2e7143b..4bca8a2 100644 (file)
@@ -31,6 +31,16 @@ struct scatterlist {
        unsigned int    length;
 };
 
+/*
+ * These macros should be used after a pci_map_sg call has been done
+ * to get bus addresses of each of the SG entries and their lengths.
+ * You should only work with the number of sg entries pci_map_sg
+ * returns, or alternatively stop on the first sg_dma_len(sg) which
+ * is 0.
+ */
+#define sg_dma_address(sg)     ((sg)->dma_address)
+#define sg_dma_len(sg)         ((sg)->length)
+
 #define ISA_DMA_THRESHOLD (0xffffffffUL)
 
 #endif /* !_ASM_SCATTERLIST_H */