From: Phil Auld <pauld@redhat.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: "Petr Štetiar" <ynezz@true.cz>,
linux-kernel@vger.kernel.org, yury.norov@gmail.com,
rafael@kernel.org
Subject: Re: aarch64 5.15.68 regression in topology/thread_siblings (huge file size and no content)
Date: Thu, 22 Sep 2022 09:18:47 -0400 [thread overview]
Message-ID: <Yyxgtx/Vr6Ar1xEe@lorien.usersys.redhat.com> (raw)
In-Reply-To: <YyxXoPmtTZHCr5pR@kroah.com>
On Thu, Sep 22, 2022 at 02:40:00PM +0200 Greg Kroah-Hartman wrote:
> On Thu, Sep 22, 2022 at 08:32:10AM -0400, Phil Auld wrote:
> > On Thu, Sep 22, 2022 at 01:32:17PM +0200 Petr Štetiar wrote:
> > > Hi,
> > >
> > > we've got a recent bug report[1], that lscpu segfaults on aarch64 board running
> > > 5.15.y kernel. It is working fine on 5.10.y kernel.
> > >
> > > I've tracked it down[2] to the issue with `topology/thread_siblings` which
> > > apart from very strange file size returns empty content. I assume, that it's
> > > somehow related to the changes done in commit bb9ec13d156e ("topology: use
> > > bin_attribute to break the size limitation of cpumap ABI"), but I didn't tried
> > > to revert it yet to verify it.
> > >
> >
> > This is actually due to a fix for that since returning 0 size breaks
> > things as well.
> >
> > 7ee951acd31a drivers/base: fix userspace break from using bin_attributes for cpumap and cpulist
> >
> > The fix for small number of cpus as you have is now in Greg's driver core tree
> >
> > d7f06bdd6ee8 drivers/base: Fix unsigned comparison to -1 in CPUMAP_FILE_MAX_BYTES
> >
> > and should work it's way back to stable trees soon.
>
> That should fix up the file size issue.
>
> The main problem being reported here is:
>
> > > Kernel 5.15.68:
> > >
> > > root@OpenWrt:/# uname -a
> > > Linux OpenWrt 5.15.68 #0 SMP Wed Sep 21 05:54:21 2022 aarch64 GNU/Linux
> > >
> > > root@OpenWrt:/# find /sys -name thread_siblings -exec ls -al {} \;
> > > -r--r--r-- 1 root root 18446744073709551615 Sep 22 08:37 /sys/devices/system/cpu/cpu1/topology/thread_siblings
> > > -r--r--r-- 1 root root 18446744073709551615 Sep 22 08:37 /sys/devices/system/cpu/cpu0/topology/thread_siblings
> > >
> > > root@OpenWrt:/# find /sys -name thread_siblings -exec cat {} \;
> > > root@OpenWrt:/#
>
> Nothing in the file in 5.15, yet 5.10:
>
> > >
> > > Kernel 5.10.138:
> > >
> > > root@OpenWrt:/# uname -a
> > > Linux OpenWrt 5.10.138 #0 SMP Sat Sep 3 02:55:34 2022 aarch64 GNU/Linux
> > >
> > > root@OpenWrt:/# find /sys -name thread_siblings -exec cat {} \;
> > > 2
> > > 1
>
> Has data in the files.
>
Good point. My eyes latched on to that huge file size for some reason ;)
> What caused that change?
I've seen the size cause problems for tools. Are we sure that it's the empty file and not
the size causing issues? Maybe something is treating that as signed again for a count of
-1 bytes (which seems like it would be a bug anyway)?
Cheers,
Phil
>
> thanks,
>
> greg k-h
>
--
next prev parent reply other threads:[~2022-09-22 13:19 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-22 11:32 Petr Štetiar
2022-09-22 12:32 ` Phil Auld
2022-09-22 12:40 ` Greg Kroah-Hartman
2022-09-22 13:18 ` Phil Auld [this message]
2022-09-22 14:05 ` Petr Štetiar
2022-09-22 17:18 ` Phil Auld
2022-09-22 20:05 ` Petr Štetiar
2022-09-23 9:16 ` Greg Kroah-Hartman
2022-09-23 13:02 ` Phil Auld
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=Yyxgtx/Vr6Ar1xEe@lorien.usersys.redhat.com \
--to=pauld@redhat.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rafael@kernel.org \
--cc=ynezz@true.cz \
--cc=yury.norov@gmail.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®