All of lore.kernel.org
 help / color / mirror / Atom feed
From: Philippe Gerum <rpm@xenomai.org>
To: Lukasz Zemla <Lukasz.Zemla@woodward.com>
Cc: "Xenomai@xenomai.org" <Xenomai@xenomai.org>
Subject: Re: [Xenomai] Xenomai installation on P1020RDB
Date: Fri, 27 Jul 2012 18:19:13 +0200	[thread overview]
Message-ID: <5012BF81.90404@xenomai.org> (raw)
In-Reply-To: <CE2E43470FE5444A811B580382FE5EDF2113EA9385@KEMPMAIL2.woodward.com>

On 07/27/2012 06:12 PM, Lukasz Zemla wrote:
>
>> -----Original Message-----
>> From: Philippe Gerum [mailto:rpm@xenomai.org]
>> Sent: Friday, July 27, 2012 6:09 PM
>> To: Gilles Chanteperdrix
>> Cc: Lukasz Zemla; Xenomai@xenomai.org
>> Subject: Re: [Xenomai] Xenomai installation on P1020RDB
>>
>> On 07/27/2012 06:00 PM, Gilles Chanteperdrix wrote:
>>> On 07/27/2012 05:53 PM, Lukasz Zemla wrote:
>>>
>>>> What I discovered, the source of the '76s problem' could be
>> preemption model. Now, when I set:
>>>>    - CONFIG_PREEMPT - the lag exists exactly after eth0
>> initialization.
>>>>    - CONFIG_PREEMPT_VOLUNTARY - the boot process stops for a while
>> (about 50-70s) in different places.
>>>>    - CONFIG_PREEMPT_NONE then all is fine, I cannot observe any
>> described problems.
>>>
>>>
>>> CONFIG_PREEMPT or PREEMPT_VOLUNTARY. Try this patch:
>>>
>>> diff --git a/arch/powerpc/kernel/ipipe.c
>> b/arch/powerpc/kernel/ipipe.c
>>> index 45302c1..5b706da 100644
>>> --- a/arch/powerpc/kernel/ipipe.c
>>> +++ b/arch/powerpc/kernel/ipipe.c
>>> @@ -344,8 +344,10 @@ static void __ipipe_do_IRQ(unsigned int irq,
>> void
>>> *cookie)
>>>
>>>    static void __ipipe_do_timer(unsigned int irq, void *cookie)
>>>    {
>>> +	irq_enter();
>>>    	check_stack_overflow();
>>>    	timer_interrupt(__this_cpu_ptr(&ipipe_percpu.tick_regs));
>>> +	irq_exit();
>>>    }
>>>
>>>    asmlinkage int __ipipe_grab_timer(struct pt_regs *regs)
>>>
>>> Or to remove the #ifdef CONFIG_IPIPE / #endif around the calls to
>>> irq_enter/irq_exit in arch/powerpc/kernel/time.c
>>>
>>
>> Mm, no. On ppc, we use a virtual irq to map the decrementer, so the
>> pipeline core already took care of marking the irq entry before calling
>> the __ipipe_do_timer handler. The issue may be in the log syncer
>> instead.
>
> Maybe I have some symptom which I forgot to write. When the system with CONFIG_PREEMPT stayed unused for last night I saw following errors:

I should be able to reproduce this issue on some hw I have access to. 
I'll have a look and let you know. Thanks.

>
> Yocto (Built by Poky 6.0) 1.1 p1020rdb ttyS0
>
> p1020rdb login: [  193.919436] INFO: rcu_preempt detected stalls on CPUs/tasks: { 1} (detected by 0, t=15002 jiffies)
> [  193.928407] Call Trace:
> [  193.930860] [c0799cb0] [c0008234] show_stack+0x4c/0x174 (unreliable)
> [  193.937222] [c0799cf0] [c0092464] __rcu_pending+0x424/0x440
> [  193.942794] [c0799d30] [c0092a84] rcu_check_callbacks+0x150/0x1f8
> [  193.948893] [c0799d50] [c0056f40] update_process_times+0x3c/0x60
> [  193.954904] [c0799d70] [c0079fe4] tick_sched_timer+0x8c/0xfc
> [  193.960570] [c0799da0] [c006bdb4] __run_hrtimer.isra.28+0x58/0x100
> [  193.966751] [c0799dc0] [c006cc3c] hrtimer_interrupt+0x160/0x408
> [  193.972673] [c0799e50] [c0009d14] timer_interrupt+0x13c/0x1b8
> [  193.978421] [c0799e80] [c000e2cc] __ipipe_do_timer+0x44/0x54
> [  193.984082] [c0799e90] [c009467c] __ipipe_do_sync_stage+0x1e0/0x220
> [  193.990350] [c0799ec0] [c000e9a0] __ipipe_grab_timer+0xa8/0xc0
> [  193.996186] [c0799ed0] [c00107a4] __ipipe_ret_from_except+0x0/0xc
> [  194.002282] --- Exception: 901 at cpu_idle+0x8c/0xf0
> [  194.002286]     LR = cpu_idle+0x8c/0xf0
> [  194.011067] [c0799f90] [c0008df8] cpu_idle+0xb0/0xf0 (unreliable)
> [  194.017165] [c0799fb0] [c0002438] rest_init+0x88/0x98
> [  194.022221] [c0799fc0] [c072778c] start_kernel+0x2e8/0x2fc
> [  194.027706] [c0799ff0] [c00003fc] skpinv+0x2e8/0x324
> [ 6662.479437] INFO: rcu_bh detected stalls on CPUs/tasks: { 1} (detected by 0, t=15002 jiffies)
> [ 6662.487975] Call Trace:
> [ 6662.490428] [c0799cb0] [c0008234] show_stack+0x4c/0x174 (unreliable)
> [ 6662.496790] [c0799cf0] [c0092464] __rcu_pending+0x424/0x440
> [ 6662.502363] [c0799d30] [c0092a68] rcu_check_callbacks+0x134/0x1f8
> [ 6662.508460] [c0799d50] [c0056f40] update_process_times+0x3c/0x60
> [ 6662.514473] [c0799d70] [c0079fe4] tick_sched_timer+0x8c/0xfc
> [ 6662.520138] [c0799da0] [c006bdb4] __run_hrtimer.isra.28+0x58/0x100
> [ 6662.526319] [c0799dc0] [c006cc3c] hrtimer_interrupt+0x160/0x408
> [ 6662.532241] [c0799e50] [c0009d14] timer_interrupt+0x13c/0x1b8
> [ 6662.537989] [c0799e80] [c000e2cc] __ipipe_do_timer+0x44/0x54
> [ 6662.543650] [c0799e90] [c009467c] __ipipe_do_sync_stage+0x1e0/0x220
> [ 6662.549917] [c0799ec0] [c000e9a0] __ipipe_grab_timer+0xa8/0xc0
> [ 6662.555752] [c0799ed0] [c00107a4] __ipipe_ret_from_except+0x0/0xc
> [ 6662.561849] --- Exception: 901 at cpu_idle+0x8c/0xf0
> [ 6662.561852]     LR = cpu_idle+0x8c/0xf0
> [ 6662.570635] [c0799f90] [c0008df8] cpu_idle+0xb0/0xf0 (unreliable)
> [ 6662.576732] [c0799fb0] [c0002438] rest_init+0x88/0x98
> [ 6662.581788] [c0799fc0] [c072778c] start_kernel+0x2e8/0x2fc
> [ 6662.587273] [c0799ff0] [c00003fc] skpinv+0x2e8/0x324
>


-- 
Philippe.




  reply	other threads:[~2012-07-27 16:19 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-20 14:31 [Xenomai] Xenomai installation on P1020RDB Lukasz Zemla
2012-07-20 18:25 ` Wolfgang Grandegger
2012-07-23  8:48   ` Richard Cochran
2012-07-23 12:01     ` Wolfgang Grandegger
2012-07-25 16:18   ` Lukasz Zemla
2012-07-25 17:11     ` Gilles Chanteperdrix
2012-07-25 17:36       ` Gilles Chanteperdrix
2012-07-25 20:15         ` Lukasz Zemla
2012-07-25 20:42           ` Gilles Chanteperdrix
2012-07-26 11:20             ` Lukasz Zemla
2012-07-26 12:00               ` Gilles Chanteperdrix
2012-07-27 15:53                 ` Lukasz Zemla
2012-07-27 16:00                   ` Gilles Chanteperdrix
2012-07-27 16:08                     ` Philippe Gerum
2012-07-27 16:12                       ` Lukasz Zemla
2012-07-27 16:19                         ` Philippe Gerum [this message]
2012-07-29 14:30                           ` Philippe Gerum
2012-07-29 14:10         ` Philippe Gerum
2012-07-25 19:26     ` Wolfgang Grandegger
2012-07-25 20:26       ` Lukasz Zemla
2012-07-25 20:55         ` Wolfgang Grandegger

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=5012BF81.90404@xenomai.org \
    --to=rpm@xenomai.org \
    --cc=Lukasz.Zemla@woodward.com \
    --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.