[Top] [All Lists]

Re: How can I access h/w registers in user space?

To: "Ardelean, Andrei" <>
Subject: Re: How can I access h/w registers in user space?
From: Manuel Lauss <>
Date: Mon, 18 Apr 2011 17:47:43 +0200
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=QyRLLGxY/FSqlugykx1mskrRCd/l1ol9tQh7da5H5YE=; b=pCLQgWzbmtztCzewVqln7YHeEaCw+2ruwJNqokK8dRKFKeGYvFCKxLtkqRPRL8aADy LKQFBU1m/XQw7IgfY8rwrzHg5JWGXxo2utpsQARanCGR2PFw3fLpP7KKjJAXgzbZCYwG l99Z7A3uLloWXNN86yGJt4Jf0H7F6RzrdppHs=
Domainkey-signature: a=rsa-sha1; c=nofws;; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=gUitwkGeJnUkl6BxfaYy6sIvOclI68qqY7KhgntB62ECokJ/vlcGk01++JmAoN7ZT7 6uyuO7hOj9rfLRzr6NxJEts+w65U7bpSyxFg+OcOYfnHhzpO5nRQNXfwKVIOA+IV6Nui RuXK+YCL4bISRiqygMSW+Lx31XBjSXZBfrSTo=
In-reply-to: <>
Original-recipient: rfc822;
References: <>
On Mon, Apr 18, 2011 at 5:41 PM, Ardelean, Andrei
<> wrote:
> 1. My video processor has many h/w registers mapped in MIPS CPU physical
> memory space. Do I have in Linux MIPS something like iopl() to allow me
> to access h/w registers in user space? Is it anything similar available?

I believe iopl() is a x86-specific hack.

> 2. I studied mmap() solution but what I found unpleased is that I need
> to malloc() space in user space equal to the IO memory space I want to
> access which it is quite lot and it takes from system DDR RAM available
> I have here. What I need is just to access a physical space which I know
> that is mapped on internal registers.

I usually open /dev/mem then simply mmap() the base of the physical area
I'm interested in.

Hope that helps!
      Manuel Lauss

<Prev in Thread] Current Thread [Next in Thread>