lkml.org 
[lkml]   [1999]   [Mar]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: user space writel() etc. in 2.2.2
From
Date
>>>>> "Alan" == Alan Cox <alan@lxorguk.ukuu.org.uk> writes:

>> in the io.h file functions to read/write IO memory
>> (writel(),readl() etc.) are only defined with __KERNEL__ macro
>> defined. Under 2.0.36 that was not the case.

Alan> Those macros arent usable in their native form

Which is believe is a problem!

>> I don't like setting __KERNEL__ for user space allications, besides
>> it produces a lot of errors when I try to compile.
>>
>> Q: what is the right way to access IO memory under 2.2.2 ?

Alan> mmio space by using mmap() as with 2.0, and pc style io space
Alan> with inb inw etc (which are exported with __KERNEL__ not
Alan> defined)

Alpha + sparse memory + mmap'ed frame buffer + mmap'ed control
registers.

I am not that familiar with the sparse mem but I doubt mmap() has a
kludge to get around it (I found out the hard way why readl/writel is
needed when porting the AceNIC driver to run an Avanti).

Jes

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

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