All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
Cc: Xenomai <xenomai@xenomai.org>
Subject: Re: [Xenomai] RTDM syscalls & switching
Date: Tue, 14 Jun 2016 18:03:20 +0200	[thread overview]
Message-ID: <57602AC8.3070506@siemens.com> (raw)
In-Reply-To: <20160614155112.GD23680@hermes.click-hack.org>

On 2016-06-14 17:51, Gilles Chanteperdrix wrote:
>> Sorry, there *is*: Shadowed thread (anything created by wrapped
>> pthread_create) calls, say, read() on some Linux file descriptor, read()
>> is wrapped, first probes the call on RTDM, which means migration to RT
>> (for currently relaxed threads, like SCHED_WEAK), no RTDM match in the
>> kernel, and finally the migration to NRT in order to do the Linux read()
>> syscall. That didn't happen with the original design.
> 
> The wrapped read does not get ping-pong when calling the Linux I/O
> syscalls. The term syscall means something very precise, and
> __wrap_read is not a syscall. It gets ping-pong because it calls
> RTDM I/O. But if you call directly Linux I/O syscall, with say
> __real_read, you do not get ping-pong. Linux I/O syscall work as
> they have always have: they require xenomai threads to run in
> secondary mode and will cause them to switch to secondary mode to
> handle the syscall.

__real_* are a non-portable workarounds for special cases. It's not what
Xenomai developers are supposed to use in their applications.

If it were, we could also give up on wrapping and have rt_task_create
etc. again, ie. separate APIs for RT and non-RT.

Jan

-- 
Siemens AG, Corporate Technology, CT RDA ITP SES-DE
Corporate Competence Center Embedded Linux


  reply	other threads:[~2016-06-14 16:03 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-12 16:06 [Xenomai] RTDM syscalls & switching Jan Kiszka
2016-05-12 16:31 ` Gilles Chanteperdrix
2016-05-12 16:50   ` Jan Kiszka
2016-05-12 16:59     ` Gilles Chanteperdrix
2016-05-12 17:12       ` Gilles Chanteperdrix
2016-05-12 17:17         ` Jan Kiszka
2016-05-12 18:20           ` Gilles Chanteperdrix
2016-05-12 18:24             ` Jan Kiszka
2016-05-12 18:30               ` Gilles Chanteperdrix
2016-05-12 18:33                 ` Jan Kiszka
2016-05-12 18:35               ` Philippe Gerum
2016-05-12 18:42                 ` Jan Kiszka
2016-05-12 19:08                   ` Philippe Gerum
2016-05-12 19:27                     ` Jan Kiszka
2016-05-12 19:47                       ` Gilles Chanteperdrix
2016-05-12 22:26                       ` Philippe Gerum
2016-05-13  5:54                         ` Jan Kiszka
2016-05-13 13:38                           ` Philippe Gerum
2016-05-13 15:32                             ` Jan Kiszka
2016-06-14 15:09                               ` Jan Kiszka
2016-06-14 15:23                                 ` Philippe Gerum
2016-06-14 15:27                                   ` Jan Kiszka
2016-06-14 15:38                                     ` Gilles Chanteperdrix
2016-06-14 15:43                                       ` Jan Kiszka
2016-06-14 15:51                                         ` Gilles Chanteperdrix
2016-06-14 16:03                                           ` Jan Kiszka [this message]
2016-06-14 16:12                                             ` Gilles Chanteperdrix
2016-06-14 16:25                                               ` Jan Kiszka
2016-06-14 16:42                                                 ` Gilles Chanteperdrix
2016-06-14 16:59                                                   ` Jan Kiszka
2016-06-14 22:12                                                     ` Gilles Chanteperdrix
2016-06-14 15:47                                     ` Jan Kiszka
2016-06-14 19:48                                     ` Philippe Gerum
2016-06-14 20:03                                       ` Jan Kiszka
2016-06-14 20:13                                         ` Philippe Gerum
2016-06-14 17:13                                   ` Jan Kiszka
2016-06-14 20:11                                     ` Philippe Gerum
2016-06-14 20:35                                       ` Gilles Chanteperdrix
2016-05-12 19:11               ` Gilles Chanteperdrix
2016-05-12 19:31                 ` Jan Kiszka
2016-05-12 19:39                   ` Gilles Chanteperdrix
2016-05-12 17:14       ` Jan Kiszka
2016-05-12 17:38     ` Philippe Gerum
2016-05-12 17:51       ` Jan Kiszka
2016-05-12 18:22         ` Gilles Chanteperdrix
2016-05-12 18:31           ` Jan Kiszka

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=57602AC8.3070506@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=gilles.chanteperdrix@xenomai.org \
    --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.