All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
To: JK.Behnke@web.de
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai] rtdm driver open_rt/nrt handler question
Date: Thu, 26 Nov 2015 10:10:52 +0100	[thread overview]
Message-ID: <20151126091052.GC19641@hermes.click-hack.org> (raw)
In-Reply-To: <trinity-1b427f3b-dabe-48c1-a434-82562a3226e1-1448528416329@3capp-webde-bs12>

On Thu, Nov 26, 2015 at 10:00:16AM +0100, JK.Behnke@web.de wrote:
>    Xenomai 2.6.3 documentation states, that the usage of open_rt handlers
>    is deprecated
>    as this feature will be removed in the future.

Xenomai 2.6.3 is very old now. It is not even the latest release in
the 2.6 branch. open_rt has been removed from Xenomai 3.

>    As a consequence one cannot use rtdm_mutex_lock inside an nrt_open
>    handler
>    to synchronize multiple callers, as this will result in a
>    (!xnpod_unblockable_p()) assertion.
>    So using a spinlock would be the only solution in that situation.
>    Is that true?

No, the caller is a Linux task, or a Xenomai task running in
secondary mode. As such, any Linux service can be used, such as
mutex or semaphores (the Linux ones).

> 
>    By the way, if an rtdm driver only supports RTDM_EXCLUSIVE mode, is
>    there
>    a need to synchronize concurrent calls to rt_dev_open on this device at
>    all?
>    I guess not, because the second caller will be refused.
>    Is that also true?

Yes.

-- 
					    Gilles.
https://click-hack.org


  reply	other threads:[~2015-11-26  9:10 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-26  9:00 [Xenomai] rtdm driver open_rt/nrt handler question JK.Behnke
2015-11-26  9:10 ` Gilles Chanteperdrix [this message]
2015-11-26  9:39   ` JK.Behnke

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=20151126091052.GC19641@hermes.click-hack.org \
    --to=gilles.chanteperdrix@xenomai.org \
    --cc=JK.Behnke@web.de \
    --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.