All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@web.de>
To: "임준수(Junesoo Im) 수석 두산로보틱스" <junesoo.im@doosan.com>,
	"xenomai@lists.linux.dev" <xenomai@lists.linux.dev>
Cc: "박경훈(Kyunghoon Park) 팀장 두산로보틱스" <kyunghoon2.park@doosan.com>,
	"김규현(Kyuhyeon Kim) - 소타텍코리아" <kyuhyeon.kim@doosan.com>,
	"Nguyen Thanh Tung(Tung Nguyenthanh) 소타텍코리아"
	<tung3.nguyenthanh@doosan.com>
Subject: Re: Linux system got freezing when "Xenomai App" started (or terminated).
Date: Wed, 31 Jul 2024 22:04:19 +0200	[thread overview]
Message-ID: <c7f22a5d-73da-4b8a-a3eb-50fb579f5c57@web.de> (raw)
In-Reply-To: <SL2P216MB2274A6A3B523862FDBA9F341E0B12@SL2P216MB2274.KORP216.PROD.OUTLOOK.COM>

On 31.07.24 11:35, 임준수(Junesoo Im) 수석 두산로보틱스 wrote:
> Dear Jan,
>
>
> I am validating our Xenomai Application with following setup:
>
>    - Xenomai version: https://source.denx.de/Xenomai/xenomai/-/tree/v3.1.4
>    - Ipipe: https://source.denx.de/Xenomai/ipipe-x86/-/tree/ipipe-core-5.4.255-x86-15
>
>
>
> During Reliability Test in which we do the loop:
>     {
>         1. Boot up machine, start Xenomai application
>         2. Wait for 1 min
>         3. Reboot Machine
>     }
>
> Sometime we face the double-unlock issue right after starting Xenomai Application as below:
>     1. [   14.046242] [Xenomai] lock 00000000733490c8 already unlocked on CPU #1
>         [   14.046242]           last owner = kernel/xenomai/posix/process.c:1243 (handle_schedule_event(), CPU #-1)
>     2. [   13.787715] [Xenomai] lock 0000000054aa4b33 already unlocked on CPU #3
>         [   13.787715]           last owner = kernel/xenomai/posix/thread.c:91 (thread_hash(), CPU #0)
> In consequence, System hung up (with Soft lock/Hard lock printed) and cannot recover.
>
>
>
> I have done some searching and found this commit:
> https://lore.kernel.org/all/9de20ac1-f92f-693e-f205-c965a2c6b434@xenomai.org/
>
> As my understanding, this issue is caused by "xnlock_get()" which does not dissable the interrupt.
> So I have some questions:
>
>     1. Do you think our issue is related to "xnlock_get()"?
>         As I checked the kernel code, there are some places still using that API, while mostly "xnlock_get_irqsave()" is used.

We may have a corner case around the reboot code - or can you also
reproduce without rebooting?

Furthermore, please test with recent versions as well. I-pipe kernels
are in maintenance mode, receiving less attention and minimal updates
these days now.

>     2. Is "nklock" could also be accessed by POSIX kernel?
>     3. Is migrating back and forth between Primary and Secondary mode safe? As we previously experienced live-lock when calling Linux VDSO gettimeofday(),

This is architectural with legacy I-pipe. Another reason to move to >
5.4, thus dovetail.

Jan


      reply	other threads:[~2024-07-31 20:04 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-15  0:43 Linux system got freezing when "Xenomai App" started (or terminated) 임준수(Junesoo Im) 수석 두산로보틱스
2024-04-15  9:23 ` 임준수(Junesoo Im) 수석 두산로보틱스
2024-04-15  9:48   ` François Legal
2024-04-15 10:07     ` 임준수(Junesoo Im) 수석 두산로보틱스
2024-04-15 10:16       ` François Legal
2024-04-15 10:37         ` 임준수(Junesoo Im) 수석 두산로보틱스
2024-04-15 13:21           ` François Legal
2024-04-29  8:49             ` 임준수(Junesoo Im) 수석 두산로보틱스
2024-04-15 13:16   ` Jan Kiszka
2024-07-31  9:35     ` 임준수(Junesoo Im) 수석 두산로보틱스
2024-07-31 20:04       ` Jan Kiszka [this message]

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=c7f22a5d-73da-4b8a-a3eb-50fb579f5c57@web.de \
    --to=jan.kiszka@web.de \
    --cc=junesoo.im@doosan.com \
    --cc=kyuhyeon.kim@doosan.com \
    --cc=kyunghoon2.park@doosan.com \
    --cc=tung3.nguyenthanh@doosan.com \
    --cc=xenomai@lists.linux.dev \
    /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.