All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
To: Bosko Radivojevic <bosko.radivojevic@domain.hid>
Cc: Xenomai help <xenomai@xenomai.org>
Subject: [Xenomai-help] Xenomai on arm926ejs based SOCs.
Date: Wed, 06 Jan 2010 22:53:44 +0100	[thread overview]
Message-ID: <4B450668.70107@domain.hid> (raw)


Hi

Short explanation: please all users of SOCs based on the arm926ejs core,
boot your xenomai-patched kernel with the "nohlt" parameter.

Long explanation: Bosko, I have finally found the reason for the strange
problem you had when an interrupt handler could take a long time to
execute when preempting the idle task, which you solved by booting the
kernel with the nohlt parameter.

The I-pipe patch modifies the ARM idle loop to run the hardware-specific
idle callback (arch_idle) with hardware interrupts enabled. But the
arm926ejs idle callback disables the I-cache, then calls the
"wait-for-interrupt" instruction, then re-enables the I-cache. So, when
CONFIG_IPIPE is active, if an interrupt happens when the idle loop is
stopped in the "wait-for-interrupt" instruction (which happens all the
time, really, on an unloaded system), the interrupt preempts the idle
loop immediately, that is before the I-cache is re-enabled, and the
whole interrupt handling, including switching-to and running some
xenomai task, happens with I-cache off. A disaster.

So, Bosko, your interrupt handler was running with I-cache off.

Obviously, next releases of the I-pipe patch will no longer call
arch_idle with hardware irqs on. But in the mean-time, you have to boot
your kernel with the nohlt parameter.

Sorry for the inconvenience.

Regards.

-- 
					    Gilles.


                 reply	other threads:[~2010-01-06 21:53 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=4B450668.70107@domain.hid \
    --to=gilles.chanteperdrix@xenomai.org \
    --cc=bosko.radivojevic@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.