]> err.no Git - linux-2.6/blobdiff - include/asm-ppc/dma-mapping.h
Merge watchdog driver updates
[linux-2.6] / include / asm-ppc / dma-mapping.h
index 7f0487afebbee99e0488465a137de11bd77e575e..92b8ee78dcc21b6a959219ec9ef8da7872fb26a7 100644 (file)
@@ -60,7 +60,8 @@ static inline int dma_set_mask(struct device *dev, u64 dma_mask)
 }
 
 static inline void *dma_alloc_coherent(struct device *dev, size_t size,
-                                      dma_addr_t * dma_handle, int gfp)
+                                      dma_addr_t * dma_handle,
+                                      unsigned int __nocast gfp)
 {
 #ifdef CONFIG_NOT_COHERENT_CACHE
        return __dma_alloc_coherent(size, dma_handle, gfp);
@@ -117,7 +118,7 @@ dma_map_page(struct device *dev, struct page *page,
 
        __dma_sync_page(page, offset, size, direction);
 
-       return (page - mem_map) * PAGE_SIZE + PCI_DRAM_OFFSET + offset;
+       return page_to_bus(page) + offset;
 }
 
 /* We do nothing. */