Re: spinlock recursion in aio_complete()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 5/22/23 22:58, Bart Van Assche wrote:
On 5/22/23 13:51, Helge Deller wrote:
On 5/22/23 21:28, Bart Van Assche wrote:
On 5/20/23 22:43, Helge Deller wrote:
On a single-CPU parisc64 machine I face the spinlock recursion below.
Happens reproduceably directly at bootup since kernel 6.2 (and ~ 6.1.5).
Kernel is built for SMP. Same kernel binary works nicely on machines with more than
one CPU, but stops on UP machines.
Any idea or patch I could try?

How about performing one or more of the following actions?
* Translating aio_complete+0x68 into a line number.

It hangs in fs/aio.c:1128, function aio_complete(), in this call:
     spin_lock_irqsave(&ctx->completion_lock, flags);

All code that I found and that obtains ctx->completion_lock disables IRQs.
It is not clear to me how this spinlock can be locked recursively? Is it
sure that the "spinlock recursion" report is correct?

Yes, it seems correct.
I can see the machine hanging in exactly the same lock when I build without
the CONFIG_DEBUG_SPINLOCK option and check the processor registers with the TOC
command (TOC on parisc means: stop CPU instruction processing, save all CPU registers
to an area which can be analyzed at a later point in time, then reboot the machine).

So, the spinlock recursion from kernel and TOC both agree.

Again, the strange thing is, that I can only reproduce it on that specific machine,
which has only one CPU but runs the SMP kernel.

Helge




[Index of Archives]     [Linux SoC]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux