All of lore.kernel.org
 help / color / mirror / Atom feed
* [Xenomai-help] Xenomai and select() function - don't work correctly
@ 2011-03-18 11:48 Jens Köhler
  2011-03-18 11:53 ` Gilles Chanteperdrix
  2011-03-18 12:05 ` Jan Kiszka
  0 siblings, 2 replies; 5+ messages in thread
From: Jens Köhler @ 2011-03-18 11:48 UTC (permalink / raw)
  To: xenomai

[-- Attachment #1: Type: text/plain, Size: 563 bytes --]

Hello,

on my atom processor based computer is Xenomai installed. (Kernel 2.6.26,
1000Hz, Xenomai 2.4.10, PREEMPT patch, no xenomai application running).

A normal linux application reads serial data from an UART
(16550A) and checks by select() function if there are new received
bytes. Select() has a timeout parameter, set to 12 milliseconds. Some times
it happens that select() waits 43 ms instead of maximum 12 ms. Result value
of select() is timeout instead of "byte received". Could this caused by
Xenomai? How could I improve it?

Thanks and regards,
Jens

[-- Attachment #2: Type: text/html, Size: 656 bytes --]

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

* Re: [Xenomai-help] Xenomai and select() function - don't work correctly
  2011-03-18 11:48 [Xenomai-help] Xenomai and select() function - don't work correctly Jens Köhler
@ 2011-03-18 11:53 ` Gilles Chanteperdrix
  2011-03-18 12:05 ` Jan Kiszka
  1 sibling, 0 replies; 5+ messages in thread
From: Gilles Chanteperdrix @ 2011-03-18 11:53 UTC (permalink / raw)
  To: Jens Köhler; +Cc: xenomai

Jens Köhler wrote:
> Hello,
> 
> on my atom processor based computer is Xenomai installed. (Kernel 2.6.26,
> 1000Hz, Xenomai 2.4.10, PREEMPT patch, no xenomai application running).
> 
> A normal linux application reads serial data from an UART
> (16550A) and checks by select() function if there are new received
> bytes. Select() has a timeout parameter, set to 12 milliseconds. Some times
> it happens that select() waits 43 ms instead of maximum 12 ms. Result value
> of select() is timeout instead of "byte received". Could this caused by
> Xenomai?

Run the same test without enabling Xenomai in the kernel configuration,
and you will know.

> How could I improve it?

Well basically, you are complaining that Linux is not real-time. We know
that, this is the reason why real-time extensions such as Xenomai or
preempt_rt exist.

-- 
                                                                Gilles.



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

* Re: [Xenomai-help] Xenomai and select() function - don't work correctly
  2011-03-18 11:48 [Xenomai-help] Xenomai and select() function - don't work correctly Jens Köhler
  2011-03-18 11:53 ` Gilles Chanteperdrix
@ 2011-03-18 12:05 ` Jan Kiszka
  2011-03-18 14:05   ` Jens Köhler
  1 sibling, 1 reply; 5+ messages in thread
From: Jan Kiszka @ 2011-03-18 12:05 UTC (permalink / raw)
  To: Jens Köhler; +Cc: xenomai

[-- Attachment #1: Type: text/plain, Size: 417 bytes --]

On 2011-03-18 12:48, Jens Köhler wrote:
> Hello,
> 
> on my atom processor based computer is Xenomai installed. (Kernel 2.6.26,
> 1000Hz, Xenomai 2.4.10, PREEMPT patch, no xenomai application running).

What does "PREEMPT patch" mean? CONFIG_PREEMPT? Then try over a recent
kernel (2.6.37) with latest ipipe patch as we fixed several issues that
affected Linux task preemption negatively on x86-32.

Jan


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 259 bytes --]

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

* Re: [Xenomai-help] Xenomai and select() function - don't work correctly
  2011-03-18 12:05 ` Jan Kiszka
@ 2011-03-18 14:05   ` Jens Köhler
  2011-03-18 22:12     ` Gilles Chanteperdrix
  0 siblings, 1 reply; 5+ messages in thread
From: Jens Köhler @ 2011-03-18 14:05 UTC (permalink / raw)
  To: Jan Kiszka; +Cc: xenomai

[-- Attachment #1: Type: text/plain, Size: 100 bytes --]

Yes, CONFIG_PREEMPT is set. We will try in first step what happens when it's
not set.

Thanks,
Jens

[-- Attachment #2: Type: text/html, Size: 204 bytes --]

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

* Re: [Xenomai-help] Xenomai and select() function - don't work correctly
  2011-03-18 14:05   ` Jens Köhler
@ 2011-03-18 22:12     ` Gilles Chanteperdrix
  0 siblings, 0 replies; 5+ messages in thread
From: Gilles Chanteperdrix @ 2011-03-18 22:12 UTC (permalink / raw)
  To: Jens Köhler; +Cc: xenomai, Jan Kiszka

Jens Köhler wrote:
> Yes, CONFIG_PREEMPT is set. We will try in first step what happens when it's
> not set.

I am sorry to insist, but IMO, you should try disabling CONFIG_XENOMAI
and CONFIG_IPIPE in the kernel configuration, in order to be sure that
these options are causing what you are seeing.

-- 
                                                                Gilles.



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

end of thread, other threads:[~2011-03-18 22:12 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-03-18 11:48 [Xenomai-help] Xenomai and select() function - don't work correctly Jens Köhler
2011-03-18 11:53 ` Gilles Chanteperdrix
2011-03-18 12:05 ` Jan Kiszka
2011-03-18 14:05   ` Jens Köhler
2011-03-18 22:12     ` Gilles Chanteperdrix

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.