Thread (11 messages) flat view 11 messages, 4 authors, 2004-03-04

Re: Re: Usage of readb() and friends...

From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Date: 2004-03-02 23:14:39

On Tue, 2004-03-02 at 23:15, Geert Uytterhoeven wrote:
On Tue, 2 Mar 2004, Kars de Jong wrote:
quoted
Which reminds me: drivers/video/fbmem.c at least seems to treat the
return value of ioremap() as a virtual address, since it calls
copy_{to,from}_user on it directly...
You're right. And the trouble there is that you can't easily find out which
ioremap() variant was used...
And... it's illegal to call copy_to/from_user on the return of
ioremap anyway. Not only for semantic reasons, but also for practical
reasons, for example, ioremap returns non cacheable space on PPC,
and copy_to/from_user uses "cache hints" to speed up the copy.

Ben.




-------------------------------------------------------
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help