diff mbox series

kern-devsrc: Drop auto.conf creation

Message ID 20220809111449.192321-1-richard.purdie@linuxfoundation.org
State Accepted, archived
Commit 8edbb540be564cebb72d7af38429405aca662bc9
Headers show
Series kern-devsrc: Drop auto.conf creation | expand

Commit Message

Richard Purdie Aug. 9, 2022, 11:14 a.m. UTC
After this commit in the mainline kernel, the quoting is different in auto.conf
compared to .config:

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=129ab0d2d9f38b9d43df35235fc66c6740d6928b

We therefore can't just copy one over the other or it leads to syntax/quoting
errors. We end up running make prepare anyway in all our tests so drop
this copy for fix 5.19 kernels.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/recipes-kernel/linux/kernel-devsrc.bb | 3 ---
 1 file changed, 3 deletions(-)

Comments

Bruce Ashfield Aug. 9, 2022, 1:16 p.m. UTC | #1
On Tue, Aug 9, 2022 at 7:14 AM Richard Purdie
<richard.purdie@linuxfoundation.org> wrote:
>
> After this commit in the mainline kernel, the quoting is different in auto.conf
> compared to .config:
>
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=129ab0d2d9f38b9d43df35235fc66c6740d6928b
>
> We therefore can't just copy one over the other or it leads to syntax/quoting
> errors. We end up running make prepare anyway in all our tests so drop
> this copy for fix 5.19 kernels.

It is safe to stop doing this manipulation now.

But I am curious, I was running on-target tests for 5.19+ and didn't
have any issues, what is breaking that I managed to miss ?

There is a risk that if the .cmd files start regenerating because of
this missing, or the different timestamp, that we'll have issues. But
putting it through the AB should show us if that is true.

Bruce

>
> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
> ---
>  meta/recipes-kernel/linux/kernel-devsrc.bb | 3 ---
>  1 file changed, 3 deletions(-)
>
> diff --git a/meta/recipes-kernel/linux/kernel-devsrc.bb b/meta/recipes-kernel/linux/kernel-devsrc.bb
> index a38d35e82ae..46d706b955f 100644
> --- a/meta/recipes-kernel/linux/kernel-devsrc.bb
> +++ b/meta/recipes-kernel/linux/kernel-devsrc.bb
> @@ -308,9 +308,6 @@ do_install() {
>      # external modules can be built
>      touch -r $kerneldir/build/Makefile $kerneldir/build/include/generated/uapi/linux/version.h
>
> -    # Copy .config to include/config/auto.conf so "make prepare" is unnecessary.
> -    cp $kerneldir/build/.config $kerneldir/build/include/config/auto.conf
> -
>      # make sure these are at least as old as the .config, or rebuilds will trigger
>      touch -r $kerneldir/build/.config $kerneldir/build/include/generated/autoconf.h 2>/dev/null || :
>      touch -r $kerneldir/build/.config $kerneldir/build/include/config/auto.conf* 2>/dev/null || :
> --
> 2.34.1
>
Richard Purdie Aug. 9, 2022, 1:26 p.m. UTC | #2
On Tue, 2022-08-09 at 09:16 -0400, Bruce Ashfield wrote:
> On Tue, Aug 9, 2022 at 7:14 AM Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> > 
> > After this commit in the mainline kernel, the quoting is different in auto.conf
> > compared to .config:
> > 
> > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=129ab0d2d9f38b9d43df35235fc66c6740d6928b
> > 
> > We therefore can't just copy one over the other or it leads to syntax/quoting
> > errors. We end up running make prepare anyway in all our tests so drop
> > this copy for fix 5.19 kernels.
> 
> It is safe to stop doing this manipulation now.
> 
> But I am curious, I was running on-target tests for 5.19+ and didn't
> have any issues, what is breaking that I managed to miss ?

https://autobuilder.yoctoproject.org/typhoon/#/builders/59/builds/5629/steps/13/logs/stdio

Basically any kernelmodule.KernelModuleTest.test_kernel_module which
was run was failing (which would run on any image with kernel-devsrc in
and a toolchain). It failed everywhere, all sdk qemu machines equally.

> There is a risk that if the .cmd files start regenerating because of
> this missing, or the different timestamp, that we'll have issues. But
> putting it through the AB should show us if that is true.

After this change is applied, the build looks a lot greener and this
issue goes away.

Cheers,

Richard
Bruce Ashfield Aug. 9, 2022, 1:29 p.m. UTC | #3
On Tue, Aug 9, 2022 at 9:26 AM Richard Purdie
<richard.purdie@linuxfoundation.org> wrote:
>
> On Tue, 2022-08-09 at 09:16 -0400, Bruce Ashfield wrote:
> > On Tue, Aug 9, 2022 at 7:14 AM Richard Purdie
> > <richard.purdie@linuxfoundation.org> wrote:
> > >
> > > After this commit in the mainline kernel, the quoting is different in auto.conf
> > > compared to .config:
> > >
> > > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=129ab0d2d9f38b9d43df35235fc66c6740d6928b
> > >
> > > We therefore can't just copy one over the other or it leads to syntax/quoting
> > > errors. We end up running make prepare anyway in all our tests so drop
> > > this copy for fix 5.19 kernels.
> >
> > It is safe to stop doing this manipulation now.
> >
> > But I am curious, I was running on-target tests for 5.19+ and didn't
> > have any issues, what is breaking that I managed to miss ?
>
> https://autobuilder.yoctoproject.org/typhoon/#/builders/59/builds/5629/steps/13/logs/stdio
>
> Basically any kernelmodule.KernelModuleTest.test_kernel_module which
> was run was failing (which would run on any image with kernel-devsrc in
> and a toolchain). It failed everywhere, all sdk qemu machines equally.

odd. I never did see that same error, and I built and installed kernel
module for all the architectures.

Bruce

>
> > There is a risk that if the .cmd files start regenerating because of
> > this missing, or the different timestamp, that we'll have issues. But
> > putting it through the AB should show us if that is true.
>
> After this change is applied, the build looks a lot greener and this
> issue goes away.
>
> Cheers,
>
> Richard
Richard Purdie Aug. 9, 2022, 2:08 p.m. UTC | #4
On Tue, 2022-08-09 at 09:29 -0400, Bruce Ashfield wrote:
> On Tue, Aug 9, 2022 at 9:26 AM Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> > 
> > On Tue, 2022-08-09 at 09:16 -0400, Bruce Ashfield wrote:
> > > On Tue, Aug 9, 2022 at 7:14 AM Richard Purdie
> > > <richard.purdie@linuxfoundation.org> wrote:
> > > > 
> > > > After this commit in the mainline kernel, the quoting is different in auto.conf
> > > > compared to .config:
> > > > 
> > > > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=129ab0d2d9f38b9d43df35235fc66c6740d6928b
> > > > 
> > > > We therefore can't just copy one over the other or it leads to syntax/quoting
> > > > errors. We end up running make prepare anyway in all our tests so drop
> > > > this copy for fix 5.19 kernels.
> > > 
> > > It is safe to stop doing this manipulation now.
> > > 
> > > But I am curious, I was running on-target tests for 5.19+ and didn't
> > > have any issues, what is breaking that I managed to miss ?
> > 
> > https://autobuilder.yoctoproject.org/typhoon/#/builders/59/builds/5629/steps/13/logs/stdio
> > 
> > Basically any kernelmodule.KernelModuleTest.test_kernel_module which
> > was run was failing (which would run on any image with kernel-devsrc in
> > and a toolchain). It failed everywhere, all sdk qemu machines equally.
> 
> odd. I never did see that same error, and I built and installed kernel
> module for all the architectures.

Did you use the oeqa code or something else? It seems odd you didn't
see it as it was quite consistent on my local system and the
autobuilders :/

Cheers,

Richard
Bruce Ashfield Aug. 9, 2022, 2:22 p.m. UTC | #5
On Tue, Aug 9, 2022 at 10:08 AM Richard Purdie
<richard.purdie@linuxfoundation.org> wrote:
>
> On Tue, 2022-08-09 at 09:29 -0400, Bruce Ashfield wrote:
> > On Tue, Aug 9, 2022 at 9:26 AM Richard Purdie
> > <richard.purdie@linuxfoundation.org> wrote:
> > >
> > > On Tue, 2022-08-09 at 09:16 -0400, Bruce Ashfield wrote:
> > > > On Tue, Aug 9, 2022 at 7:14 AM Richard Purdie
> > > > <richard.purdie@linuxfoundation.org> wrote:
> > > > >
> > > > > After this commit in the mainline kernel, the quoting is different in auto.conf
> > > > > compared to .config:
> > > > >
> > > > > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=129ab0d2d9f38b9d43df35235fc66c6740d6928b
> > > > >
> > > > > We therefore can't just copy one over the other or it leads to syntax/quoting
> > > > > errors. We end up running make prepare anyway in all our tests so drop
> > > > > this copy for fix 5.19 kernels.
> > > >
> > > > It is safe to stop doing this manipulation now.
> > > >
> > > > But I am curious, I was running on-target tests for 5.19+ and didn't
> > > > have any issues, what is breaking that I managed to miss ?
> > >
> > > https://autobuilder.yoctoproject.org/typhoon/#/builders/59/builds/5629/steps/13/logs/stdio
> > >
> > > Basically any kernelmodule.KernelModuleTest.test_kernel_module which
> > > was run was failing (which would run on any image with kernel-devsrc in
> > > and a toolchain). It failed everywhere, all sdk qemu machines equally.
> >
> > odd. I never did see that same error, and I built and installed kernel
> > module for all the architectures.
>
> Did you use the oeqa code or something else? It seems odd you didn't
> see it as it was quite consistent on my local system and the
> autobuilders :/

I run everything by hand, oeqa has always taken too long in my
infrastructure, so I run the kernel tests myself.

Bruce

>
> Cheers,
>
> Richard
>
Richard Purdie Aug. 9, 2022, 2:26 p.m. UTC | #6
On Tue, 2022-08-09 at 10:22 -0400, Bruce Ashfield wrote:
> On Tue, Aug 9, 2022 at 10:08 AM Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> > 
> > On Tue, 2022-08-09 at 09:29 -0400, Bruce Ashfield wrote:
> > > On Tue, Aug 9, 2022 at 9:26 AM Richard Purdie
> > > <richard.purdie@linuxfoundation.org> wrote:
> > > > 
> > > > On Tue, 2022-08-09 at 09:16 -0400, Bruce Ashfield wrote:
> > > > > On Tue, Aug 9, 2022 at 7:14 AM Richard Purdie
> > > > > <richard.purdie@linuxfoundation.org> wrote:
> > > > > > 
> > > > > > After this commit in the mainline kernel, the quoting is different in auto.conf
> > > > > > compared to .config:
> > > > > > 
> > > > > > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=129ab0d2d9f38b9d43df35235fc66c6740d6928b
> > > > > > 
> > > > > > We therefore can't just copy one over the other or it leads to syntax/quoting
> > > > > > errors. We end up running make prepare anyway in all our tests so drop
> > > > > > this copy for fix 5.19 kernels.
> > > > > 
> > > > > It is safe to stop doing this manipulation now.
> > > > > 
> > > > > But I am curious, I was running on-target tests for 5.19+ and didn't
> > > > > have any issues, what is breaking that I managed to miss ?
> > > > 
> > > > https://autobuilder.yoctoproject.org/typhoon/#/builders/59/builds/5629/steps/13/logs/stdio
> > > > 
> > > > Basically any kernelmodule.KernelModuleTest.test_kernel_module which
> > > > was run was failing (which would run on any image with kernel-devsrc in
> > > > and a toolchain). It failed everywhere, all sdk qemu machines equally.
> > > 
> > > odd. I never did see that same error, and I built and installed kernel
> > > module for all the architectures.
> > 
> > Did you use the oeqa code or something else? It seems odd you didn't
> > see it as it was quite consistent on my local system and the
> > autobuilders :/
> 
> I run everything by hand, oeqa has always taken too long in my
> infrastructure, so I run the kernel tests myself.

You could do something like:

IMAGE_CLASSES += "testimage"
TEST_SUTITES = "ping ssh kernelmodule"

and then

bitbake core-image-sato-sdk
bitbake core-image-sato-sdk -c testimage

just to run that one.

(I might have missed a test dependency which would need to be added to
the list in TEST_SUITES but you get the idea)

Cheers,

Richard
diff mbox series

Patch

diff --git a/meta/recipes-kernel/linux/kernel-devsrc.bb b/meta/recipes-kernel/linux/kernel-devsrc.bb
index a38d35e82ae..46d706b955f 100644
--- a/meta/recipes-kernel/linux/kernel-devsrc.bb
+++ b/meta/recipes-kernel/linux/kernel-devsrc.bb
@@ -308,9 +308,6 @@  do_install() {
     # external modules can be built
     touch -r $kerneldir/build/Makefile $kerneldir/build/include/generated/uapi/linux/version.h
 
-    # Copy .config to include/config/auto.conf so "make prepare" is unnecessary.
-    cp $kerneldir/build/.config $kerneldir/build/include/config/auto.conf
-
     # make sure these are at least as old as the .config, or rebuilds will trigger
     touch -r $kerneldir/build/.config $kerneldir/build/include/generated/autoconf.h 2>/dev/null || :
     touch -r $kerneldir/build/.config $kerneldir/build/include/config/auto.conf* 2>/dev/null || :