lkml.org 
[lkml]   [2022]   [Sep]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: aarch64 5.15.68 regression in topology/thread_siblings (huge file size and no content)
On Thu, Sep 22, 2022 at 04:05:04PM +0200 Petr Štetiar wrote:
> Phil Auld <pauld@redhat.com> [2022-09-22 09:18:47]:
>
> Hi,
>
> > 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)?
>
> root@OpenWrt:/# strace cat /sys/devices/system/cpu/cpu1/topology/thread_siblings
> ...snip...
> openat(AT_FDCWD, "/sys/devices/system/cpu/cpu1/topology/thread_siblings", O_RDONLY|O_LARGEFILE) = 3
> sendfile(1, 3, NULL, 16777216) = 0
>
> root@OpenWrt:/# strace md5sum /sys/devices/system/cpu/cpu1/topology/thread_sibli
> ...snip...
> openat(AT_FDCWD, "/sys/devices/system/cpu/cpu1/topology/thread_siblings", O_RDONLY|O_LARGEFILE) = 3
> read(3, "", 4096) = 0
>
> root@OpenWrt:/# strace head /sys/devices/system/cpu/cpu1/topology/thread_siblings
> ...snip...
> openat(AT_FDCWD, "/sys/devices/system/cpu/cpu1/topology/thread_siblings", O_RDONLY|O_LARGEFILE) = 3
> read(3, "", 1024) = 0
>

I tried this with the latest upstream (which doesn't yet have the fix
for the size issue) and got the same results.

Then I applied the fix and the problem went away:

6.0.0-rc6.nr_cpus2+
# find /sys -name thread_siblings -exec cat \{\} \;
2
1

Cheers,
Phil

> Cheers,
>
> Petr
>

--

\
 
 \ /
  Last update: 2022-09-22 19:20    [W:0.053 / U:0.808 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site