lkml.org 
[lkml]   [2001]   [Oct]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: how to get virtual address from dma address
From
   From: Paul Mackerras <paulus@samba.org>
Date: Sat, 6 Oct 2001 18:06:23 +1000 (EST)

The argument for supplying this functionality in the PCI DMA code
would be that if it was done there it could be done once, and in a
sophisticated and efficient (and SMP-safe :) fashion, rather than
ad-hoc in each driver.

The argument against it is that if you provide such an easy way out,
people will just blindly transform bus_to_virt/virt_to_bus without
considering more straightforward methods when they exist.

I can not even count on one hand how many people I've helped
converting, who wanted a bus_to_virt() and when I showed them
how to do it with information the device provided already they
said "oh wow, I never would have thought of that". That process
won't happen as often with the suggested feature.

I am adamently against generic infrastructure to do this. Yes, it's
social engineering, tough cookies... it's social engineering that I
know is working :-)

Franks a lot,
David S. Miller
davem@redhat.com
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:04    [W:0.085 / U:0.232 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site