Re: [PATCH 3/5] kbuild: rename cmd_{bzip2,lzma,lzo,lz4,xzkern,zstd22}

Eugeniu Rosca
2023-07-25T09:24:47Z

Hello Yamada-san,

Appreciate your willingness to support. Some findings below.

On Sun, Jul 23, 2023 at 01:08:46AM +0900, Masahiro Yamada wrote:
> On Thu, Jul 20, 2023 at 4:09 AM Eugeniu Rosca <erosca@de.adit-jv.com> wrote:
> > On Fri, Jun 23, 2023 at 04:45:44PM +0200, Eugeniu Rosca wrote:

[..]

> > > I will continue to increase my understanding behind what's happening.
> > > In case there are already any suggestions, would appreciate those.
> >
> > JFYI, we've got confirmation from Qualcomm Customer Support interface
> > that reverting [1] heals the issue on QC end as well. However, it looks
> > like none of us has clear understanding how to properly
> > troubleshoot/trace/compare the behavior before and after the commit.
> >
> > I would happily follow any suggestions.
> >
> > > [1] https://android.googlesource.com/kernel/common/+/bc6d3d83539512
> > > ("UPSTREAM: kbuild: rename cmd_{bzip2,lzma,lzo,lz4,xzkern,zstd22}")
> > >
> > > [2] https://lore.kernel.org/linux-kbuild/20230616194505.GA27753@lxhi-065/

[..]

> Please backport 64d8aaa4ef388b22372de4dc9ce3b9b3e5f45b6c
> and see if the problem goes away.

Unfortunately, the problem remains after backporting the above commit.

After some more bisecting and some more trial-and-error, I finally came
up with a reproduction scenario against vanilla. It also shows that
after reverting 7ce7e984ab2b21 ("kbuild: rename
cmd_{bzip2,lzma,lzo,lz4,xzkern,zstd22}"), the problem goes away.

It takes <30 seconds to reproduce the issue on my machine (on 2nd run).

In order to make the test self-sufficient, it also clones the Linux
sources (only during 1st run, with --depth 1, for minimal footprint),
hence ~1.8 GB free space is required in /tmp .

The repro.sh script:
=> https://gist.github.com/erosca/1372fdc24126dc98031444613450c494

Output against vanilla on 1st run (always OK, matches real-life case):
=> https://gist.github.com/erosca/0f5b8e0a00a256d80f0c8a6364d81568

Output against vanilla on 2nd/Nth run (NOK: Argument list too long):
=> https://gist.github.com/erosca/e5c2c6479cc32244cc38d308deea4cf5

Output against vanilla + revert_of_7ce7e984ab2b2 on Nth run (always OK):
=> https://gist.github.com/erosca/57e114f92ea20132e19fc7f5a46e7c65

Would it be possible to get your thoughts on the above?

--
Best regards,
Eugeniu Rosca