* [Xenomai-help] Mem mapped i/o in RTDM driver
@ 2009-04-23 18:55 jeff angielski
2009-04-30 13:40 ` Philippe Gerum
2009-04-30 13:48 ` Philippe Gerum
0 siblings, 2 replies; 4+ messages in thread
From: jeff angielski @ 2009-04-23 18:55 UTC (permalink / raw)
To: Xenomai-help
A basic RTDM question:
In a normal Linux device driver you typically use request_mem_region()
and ioremap_nocache() to setup access to some memory mapped i/o. Then
you just iowrite()/ioread() to/from that address.
Do I still do this for the XXXXX_nrt operations in my RTDM driver?
How about for the XXXX_rt operations?
I do see that gpioirqbench uses the Linux memory management indirectly
since it relies on the OF mpc52xx_find_and_map("mpc5200-gpio") but
because the driver supports both Linux and RTDM, the requirements are
not clear.
Thanks.
--
Jeff Angielski
The PTR Group
www.theptrgroup.com
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Xenomai-help] Mem mapped i/o in RTDM driver
2009-04-23 18:55 [Xenomai-help] Mem mapped i/o in RTDM driver jeff angielski
@ 2009-04-30 13:40 ` Philippe Gerum
2009-04-30 13:48 ` Philippe Gerum
1 sibling, 0 replies; 4+ messages in thread
From: Philippe Gerum @ 2009-04-30 13:40 UTC (permalink / raw)
To: jeff angielski; +Cc: Xenomai-help
On Thu, 2009-04-23 at 14:55 -0400, jeff angielski wrote:
> A basic RTDM question:
>
> In a normal Linux device driver you typically use request_mem_region()
> and ioremap_nocache() to setup access to some memory mapped i/o. Then
> you just iowrite()/ioread() to/from that address.
>
> Do I still do this for the XXXXX_nrt operations in my RTDM driver?
Yes.
>
> How about for the XXXX_rt operations?
>
ioread/iowrite will be usable the same way, but you will have to
ioremap() in a non RT context first.
> I do see that gpioirqbench uses the Linux memory management indirectly
> since it relies on the OF mpc52xx_find_and_map("mpc5200-gpio") but
> because the driver supports both Linux and RTDM, the requirements are
> not clear.
Care is taken to always refer to MPC52xx_GPIO from a plain Linux
context.
>
> Thanks.
>
>
--
Philippe.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Xenomai-help] Mem mapped i/o in RTDM driver
2009-04-23 18:55 [Xenomai-help] Mem mapped i/o in RTDM driver jeff angielski
2009-04-30 13:40 ` Philippe Gerum
@ 2009-04-30 13:48 ` Philippe Gerum
2009-04-30 13:57 ` Philippe Gerum
1 sibling, 1 reply; 4+ messages in thread
From: Philippe Gerum @ 2009-04-30 13:48 UTC (permalink / raw)
To: jeff angielski; +Cc: Xenomai-help
On Thu, 2009-04-23 at 14:55 -0400, jeff angielski wrote:
> A basic RTDM question:
>
> In a normal Linux device driver you typically use request_mem_region()
> and ioremap_nocache() to setup access to some memory mapped i/o. Then
> you just iowrite()/ioread() to/from that address.
Btw, maybe readb/w/l() and writeb/w/l() are more appropriate since
ioread/write is a legacy interface?
>
> Do I still do this for the XXXXX_nrt operations in my RTDM driver?
>
> How about for the XXXX_rt operations?
>
> I do see that gpioirqbench uses the Linux memory management indirectly
> since it relies on the OF mpc52xx_find_and_map("mpc5200-gpio") but
> because the driver supports both Linux and RTDM, the requirements are
> not clear.
>
> Thanks.
>
>
--
Philippe.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Xenomai-help] Mem mapped i/o in RTDM driver
2009-04-30 13:48 ` Philippe Gerum
@ 2009-04-30 13:57 ` Philippe Gerum
0 siblings, 0 replies; 4+ messages in thread
From: Philippe Gerum @ 2009-04-30 13:57 UTC (permalink / raw)
To: jeff angielski; +Cc: Xenomai-help
On Thu, 2009-04-30 at 15:48 +0200, Philippe Gerum wrote:
> On Thu, 2009-04-23 at 14:55 -0400, jeff angielski wrote:
> > A basic RTDM question:
> >
> > In a normal Linux device driver you typically use request_mem_region()
> > and ioremap_nocache() to setup access to some memory mapped i/o. Then
> > you just iowrite()/ioread() to/from that address.
>
> Btw, maybe readb/w/l() and writeb/w/l() are more appropriate since
> ioread/write is a legacy interface?
i.e. in MMIO mode.
>
> >
> > Do I still do this for the XXXXX_nrt operations in my RTDM driver?
> >
> > How about for the XXXX_rt operations?
> >
> > I do see that gpioirqbench uses the Linux memory management indirectly
> > since it relies on the OF mpc52xx_find_and_map("mpc5200-gpio") but
> > because the driver supports both Linux and RTDM, the requirements are
> > not clear.
> >
> > Thanks.
> >
> >
--
Philippe.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-04-30 13:57 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-04-23 18:55 [Xenomai-help] Mem mapped i/o in RTDM driver jeff angielski
2009-04-30 13:40 ` Philippe Gerum
2009-04-30 13:48 ` Philippe Gerum
2009-04-30 13:57 ` Philippe Gerum
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.