From: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
To: Fillod Stephane <stephane.fillod@domain.hid>
Cc: xenomai-help <xenomai@xenomai.org>
Subject: Re: [Xenomai-help] RTDM mmap and DMA
Date: Fri, 28 Dec 2007 22:59:16 +0100 [thread overview]
Message-ID: <18293.29108.751031.894998@domain.hid> (raw)
In-Reply-To: <0B45E93C5FF65740AEAE690BF3848B7A4AB2FB@rennsmail04.eu.thmulti.com>
Fillod Stephane wrote:
> Gilles Chanteperdrix wrote:
> >Fillod Stephane wrote:
> > > Perrine Martignoni wrote:
> > > >Currently, I write an RTDM module and I would like to do DMA and
> mmap
> > > to perform transfers who have hard constraints.
> > > >I would like to know if there is an example in a driver who would
> help
> > > me to do this.
> > >
> > > I'm looking for the same need, except I'm not using RTDM, and
> everything
> > > is in userland. Using the attached patch against Xenomai 2.4.0, I
> hope
> > > to make it to work with something like this:
> >
> >I propose the attached modifications. Is it Ok for you ?
>
> Yes, your patch is much cleaner, esp. wrt KMALLOC_MAX_SIZE which I was
> not aware of.
>
> The documentation needs an update, and a link to RT_HEAP_INFO.
> Does any Doxygen guru knows how to make rt_heap_inquire a hyperlink
> in the above chunk?
Ok. I merged the patch I sent, as well as this patch (fixed to make
rt_heap_inquire a hyperlink) in trunk. However, I did not commit it in
the v2.[34].x branch, since it is a patch which breaks the ABI (size of
the rt_heap_info structure changes). Should I increment the ABI revision
?
>
> --- ksrc/skins/native/heap.c 17 Dec 2007 14:36:15 -0000 1.6
> +++ ksrc/skins/native/heap.c 27 Dec 2007 15:23:06 -0000
> @@ -201,8 +201,8 @@
> *
> * - H_DMA causes the block pool associated to the heap to be
> * allocated in physically contiguous memory, suitable for DMA
> - * operations with I/O devices. A 128Kb limit exists for @a heapsize
> - * when this flag is passed.
> + * operations with I/O devices. The physical address of the
> + * heap can be obtained by a call to rt_heap_inquire.
> *
> * @return 0 is returned upon success. Otherwise:
> *
> --- include/native/heap.h 17 Dec 2007 14:36:09 -0000 1.2
> +++ include/native/heap.h 27 Dec 2007 15:34:22 -0000
> @@ -34,6 +34,10 @@
> #define H_SINGLE 0x400 /* Manage as single-block area. */
> #define H_SHARED (H_MAPPABLE|H_SINGLE) /* I.e. shared memory segment.
> */
Beware: your mailer broke your patch by adding a newline. It may be a
better idea to send the patch as a plain text attachment, it avoids such
surprises. I have already seen a site explaining how to teach your
mailer not to do this, but I do not have the URL at hand.
>
> +/** Structure containing heap-information useful to users.
> + *
> + * @see rt_heap_inquire()
> + */
> typedef struct rt_heap_info {
>
> int nwaiters; /* !< Number of pending tasks. */
>
> Thanks!
> --
> Stephane
--
Gilles Chanteperdrix.
next prev parent reply other threads:[~2007-12-28 21:59 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-12-27 15:39 [Xenomai-help] RTDM mmap and DMA Fillod Stephane
2007-12-27 15:43 ` Gilles Chanteperdrix
2007-12-28 21:59 ` Gilles Chanteperdrix [this message]
-- strict thread matches above, loose matches on Subject: below --
2008-01-03 18:40 Fillod Stephane
2007-12-18 17:40 Fillod Stephane
2007-12-18 17:55 ` Gilles Chanteperdrix
2007-12-17 14:40 Fillod Stephane
2007-12-14 13:59 Fillod Stephane
2007-12-14 15:50 ` Perrine Martignoni
2007-12-23 13:09 ` Gilles Chanteperdrix
2007-12-26 23:37 ` Gilles Chanteperdrix
2007-12-14 11:24 Perrine Martignoni
2007-12-18 9:21 ` Stéphane ANCELOT
2007-12-18 9:29 ` Jan Kiszka
2007-12-18 10:10 ` Gilles Chanteperdrix
2007-12-18 10:16 ` Perrine Martignoni
2007-12-18 10:18 ` Gilles Chanteperdrix
2007-12-18 10:12 ` Perrine Martignoni
2007-12-18 12:47 ` Jan Kiszka
2007-12-18 13:20 ` Gilles Chanteperdrix
2007-12-18 14:11 ` Perrine Martignoni
2007-12-18 14:22 ` Jan Kiszka
2007-12-18 14:41 ` Perrine Martignoni
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=18293.29108.751031.894998@domain.hid \
--to=gilles.chanteperdrix@xenomai.org \
--cc=stephane.fillod@domain.hid \
--cc=xenomai@xenomai.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.