From: Konrad Rzeszutek Wilk Date: Thu, 2 Dec 2010 16:04:29 +0000 (-0500) Subject: radeon/ttm/PCIe: Use dma_addr if TTM has set it. X-Git-Tag: v2.6.39-rc1~458^2~23^2~2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c39d35161e87f1d7c0628af6907ac66a8c77f63f;p=pandora-kernel.git radeon/ttm/PCIe: Use dma_addr if TTM has set it. If the TTM layer has used the DMA API to setup pages that are TTM_PAGE_FLAG_DMA32 (look at patch titled: "ttm: Utilize the dma_addr_t array for pages that are to in DMA32 pool."), lets use it when programming the GART in the PCIe type cards. This patch skips doing the pci_map_page (and pci_unmap_page) if there is a DMA addresses passed in for that page. If the dma_address is zero (or DMA_ERROR_CODE), then we continue on with our old behaviour. [v2: Fixed an indentation problem, added reviewed-by tag] [v3: Added Acked-by Jerome] Acked-by: Jerome Glisse Reviewed-by: Thomas Hellstrom Signed-off-by: Konrad Rzeszutek Wilk Tested-by: Ian Campbell --- Reading git-diff-tree failed