lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <23b67f9d-20ff-4302-810c-bf2d77c52c63@linux.dev>
Date: Wed, 8 Oct 2025 15:09:43 +0800
From: Lance Yang <lance.yang@...ux.dev>
To: Finn Thain <fthain@...ux-m68k.org>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
 Geert Uytterhoeven <geert@...ux-m68k.org>, Eero Tamminen
 <oak@...sinkinet.fi>, Kent Overstreet <kent.overstreet@...ux.dev>,
 amaindex@...look.com, anna.schumaker@...cle.com, boqun.feng@...il.com,
 ioworker0@...il.com, joel.granados@...nel.org, jstultz@...gle.com,
 leonylgao@...cent.com, linux-kernel@...r.kernel.org,
 linux-m68k@...ts.linux-m68k.org, longman@...hat.com, mhiramat@...nel.org,
 mingo@...hat.com, mingzhe.yang@...com, peterz@...radead.org,
 rostedt@...dmis.org, senozhatsky@...omium.org, tfiga@...omium.org,
 will@...nel.org, stable@...r.kernel.org
Subject: Re: [PATCH v2 1/1] hung_task: fix warnings caused by unaligned lock
 pointers



On 2025/10/8 14:14, Finn Thain wrote:
> 
> On Wed, 8 Oct 2025, Lance Yang wrote:
> 
>> On 2025/10/8 08:40, Finn Thain wrote:
>>>
>>> On Tue, 7 Oct 2025, Andrew Morton wrote:
>>>
>>>> Getting back to the $Subject at hand, are people OK with proceeding
>>>> with Lance's original fix?
>>>>
>>>
>>> Lance's patch is probably more appropriate for -stable than the patch I
>>> proposed -- assuming a fix is needed for -stable.
>>
>> Thanks!
>>
>> Apart from that, I believe this fix is still needed for the hung task
>> detector itself, to prevent unnecessary warnings in a few unexpected
>> cases.
>>
> 
> Can you be more specific about those cases? A fix for a theoretical bug
> doesn't qualify for -stable branches. But if it's a fix for a real bug, I
> have misunderstood Andrew's question...

I believe it is a real bug, as it was reported by Eero and Geert[1].

The blocker tracking mechanism in -stable assumes that lock pointers
are at least 4-byte aligned. As I mentioned previously[2], this
assumption fails for packed structs on architectures that don't trap
on unaligned access.

Of course, we could always improve the mechanism to not make
assumptions. But for -stable, this fix completely resolves the issue
by ignoring any unaligned pointer, whatever the cause (e.g., packed
structs, non-native alignment, etc.).

So we can all sleep well at night again :)

[1] 
https://lore.kernel.org/lkml/CAMuHMdW7Ab13DdGs2acMQcix5ObJK0O2dG_Fxzr8_g58Rc1_0g@mail.gmail.com/
[2] 
https://lore.kernel.org/lkml/cfb62b9d-9cbd-47dd-a894-3357027e2a50@linux.dev/

> 
>>>
>>> Besides those two alternatives, there is also a workaround:
>>> $ ./scripts/config -d DETECT_HUNG_TASK_BLOCKER
>>> which may be acceptable to the interested parties (i.e. m68k users).
>>>
>>> I don't have a preference. I'll leave it up to the bug reporters (Eero
>>> and Geert).
>>


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ