public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Accessing peripheral register directly from userspace
@ 2010-04-12 17:01 Krishna Gopal
  2010-04-13 11:36 ` Clemens Ladisch
  0 siblings, 1 reply; 2+ messages in thread
From: Krishna Gopal @ 2010-04-12 17:01 UTC (permalink / raw)
  To: linux-kernel

Would there be any issues for optimization purpose I do a mmap to a
peripheral register to directly access it from userspace ? This is
considering the peripheral already has a Kernel driver through which
you can set the register bit.

Basically I want to avoid the additional context switch on entering
the Kernel to set that one bit in the Peripheral register.

I request you to please share your thoughts.

Best regards,
Krishna

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Accessing peripheral register directly from userspace
  2010-04-12 17:01 Accessing peripheral register directly from userspace Krishna Gopal
@ 2010-04-13 11:36 ` Clemens Ladisch
  0 siblings, 0 replies; 2+ messages in thread
From: Clemens Ladisch @ 2010-04-13 11:36 UTC (permalink / raw)
  To: Krishna Gopal; +Cc: linux-kernel

Krishna Gopal wrote:
> Would there be any issues for optimization purpose I do a mmap to a
> peripheral register to directly access it from userspace ?

This means that userspace could access any register in the same page.

Usually this is done only with read-only pages and with devices that
are designed for this so that all accessible registers are 'safe'.


Regards,
Clemens

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-04-13 11:37 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-04-12 17:01 Accessing peripheral register directly from userspace Krishna Gopal
2010-04-13 11:36 ` Clemens Ladisch

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox