virtual memmap and page_address

From: Jesse Barnes <jbarnes_at_engr.sgi.com>
Date: 2004-12-16 04:53:32
I've been messing around with some of the drm drivers lately, and in some 
cases they'll call pci_map_single on an address returned from page_address().  
When virtual memmaps are enabled, page_address will return a region 5 
pointer.  It looks like all of the ia64 iommu code (swiotlb, sba_iommu and 
sn2's pci_dma) assume that the address passed in is an identity mapped 
address since they use __pa to get the physical address.  This is fast, but 
also incorrect when the routines are handed a region 5 address.  So we either 
have to fix our iommu mapping routines or change some other assumptions 
(either about what page_address should return or what __va in general means 
for example).  Turning on WANT_PAGE_VIRTUAL and populating page->virtual with 
an identity mapped address is another option, probably less expensive than 
switching to ia64_tpa in the mapping routines.

Comments?

Thanks,
Jesse
-
To unsubscribe from this list: send the line "unsubscribe linux-ia64" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Received on Wed Dec 15 12:53:46 2004

This archive was generated by hypermail 2.1.8 : 2005-08-02 09:20:33 EST