Re: [linux-yocto] Can't compile kernel module under kirkstone

2023-03-08 Thread Bruce Ashfield
On Mon, Mar 6, 2023 at 12:36 PM Bruce Ashfield via
lists.yoctoproject.org
 wrote:
>
> On Sat, Mar 4, 2023 at 4:09 AM  wrote:
> >
> > Hi Bruce,
> > Thanks, I missed the "make scripts prepare" 8 years has past since I did 
> > this the last time.
> > Now I can compile and load the driver but still get the warning.
> >
> > warning: the compiler differs from the one used to build the kernel
> >   The kernel was built by: x86_64-poky-linux-gcc (GCC) 11.3.0
> >   You are using:   gcc (GCC) 11.3.0
> >
> >
> > So something is not 100% correct.
>
> That is expected at the moment, since we are cross compiling on the
> host, but natively building on the target.
>
> kernel-devsrc takes steps to ensure that kernel reconfiguration
> doesn't happen on target (which I assume you aren't seeing), but it
> doesn't fix that up.
>
> In kernel devsrc, I could also fix that compiler string in the
> captured .config, but we can't change the kernel-build-artifacts
> .config, as it is used for future cross builds.

I've fixed the compiler strings in kernel-devsrc, so there's no longer
a warning on the target.

I'll include the change in one of my next pull requests.

Bruce

>
> Bruce
>
> >
> > Kind regards
> > Anders
> >
> >
> >
> > -Original Message-----
> > From: linux-yocto@lists.yoctoproject.org 
> >  On Behalf Of Bruce Ashfield
> > Sent: den 3 mars 2023 19:08
> > To: Anders Berndtsson 
> > Cc: linux-yocto@lists.yoctoproject.org
> > Subject: Re: [linux-yocto] Can't compile kernel module under kirkstone
> >
> > On Fri, Mar 3, 2023 at 12:23 PM Anders Berndtsson 
> >  wrote:
> > >
> > > Get this message when compiling a kernel module under branch kirkstone
> > > and intel-corei7-64
> > > warning: the compiler differs from the one used to build the kerne
> > >   The kernel was built by: x86_64-poky-linux-gcc (GCC) 11.3.0
> > >   You are using:   gcc (GCC) 11.3.0
> > > cat /proc/version
> > > Linux version 5.15.85-intel-pk-standard (oe-user@oe-host)
> > > (x86_64-poky-linux-gcc (GCC) 11.3.0, GNU ld (GNU Binutils)
> > > 2.38.20220708) #1 SMP PREEMPT Wed Jan 11 19:36:47 UTC 2023 gcc
> > > --version gcc (GCC) 11.3.0 Copyright (C) 2021 Free Software Foundation, 
> > > Inc.
> > > This is free software; see the source for copying conditions.  There
> > > is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR 
> > > PURPOSE.
> >
> > So you are building the module on target ? If so, that is something we test 
> > nightly, and as part of the release builds, so it is known to work for all 
> > releases (i.e. we won't release with it broken).
> >
> > >
> > > But I actual believe that I use the same compiler as the one used to 
> > > build the kernel.
> > > I suspect that the version format from the gcc compiler has changed so 
> > > the compare of the versions don't work.
> > >
> > > The kernel compiling works for an old Yocto kernel 3.19.5  from 2015  
> > > with same makefile and source file.
> >
> > A kernel of that vintage wouldn't have checks for the compiler.
> >
> > We'd have to know more about your image, your layers, if kernel-devsrc is 
> > installed on target, and if you've done "make scripts prepare"
> > before starting to build the module.
> >
> > Bruce
> >
> > >
> > >
> > >
> > >
> >
> >
> > --
> > - Thou shalt not follow the NULL pointer, for chaos and madness await thee 
> > at its end
> > - "Use the force Harry" - Gandalf, Star Trek II
> >
>
>
> --
> - Thou shalt not follow the NULL pointer, for chaos and madness await
> thee at its end
> - "Use the force Harry" - Gandalf, Star Trek II
>
> 
>


-- 
- Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end
- "Use the force Harry" - Gandalf, Star Trek II

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#12242): 
https://lists.yoctoproject.org/g/linux-yocto/message/12242
Mute This Topic: https://lists.yoctoproject.org/mt/97367211/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: 
https://lists.yoctoproject.org/g/linux-yocto/leave/6687884/21656/624485779/xyzzy
 [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [linux-yocto] Can't compile kernel module under kirkstone

2023-03-06 Thread Bruce Ashfield
On Sat, Mar 4, 2023 at 4:09 AM  wrote:
>
> Hi Bruce,
> Thanks, I missed the "make scripts prepare" 8 years has past since I did this 
> the last time.
> Now I can compile and load the driver but still get the warning.
>
> warning: the compiler differs from the one used to build the kernel
>   The kernel was built by: x86_64-poky-linux-gcc (GCC) 11.3.0
>   You are using:   gcc (GCC) 11.3.0
>
>
> So something is not 100% correct.

That is expected at the moment, since we are cross compiling on the
host, but natively building on the target.

kernel-devsrc takes steps to ensure that kernel reconfiguration
doesn't happen on target (which I assume you aren't seeing), but it
doesn't fix that up.

In kernel devsrc, I could also fix that compiler string in the
captured .config, but we can't change the kernel-build-artifacts
.config, as it is used for future cross builds.

Bruce

>
> Kind regards
> Anders
>
>
>
> -Original Message-
> From: linux-yocto@lists.yoctoproject.org  
> On Behalf Of Bruce Ashfield
> Sent: den 3 mars 2023 19:08
> To: Anders Berndtsson 
> Cc: linux-yocto@lists.yoctoproject.org
> Subject: Re: [linux-yocto] Can't compile kernel module under kirkstone
>
> On Fri, Mar 3, 2023 at 12:23 PM Anders Berndtsson 
>  wrote:
> >
> > Get this message when compiling a kernel module under branch kirkstone
> > and intel-corei7-64
> > warning: the compiler differs from the one used to build the kerne
> >   The kernel was built by: x86_64-poky-linux-gcc (GCC) 11.3.0
> >   You are using:   gcc (GCC) 11.3.0
> > cat /proc/version
> > Linux version 5.15.85-intel-pk-standard (oe-user@oe-host)
> > (x86_64-poky-linux-gcc (GCC) 11.3.0, GNU ld (GNU Binutils)
> > 2.38.20220708) #1 SMP PREEMPT Wed Jan 11 19:36:47 UTC 2023 gcc
> > --version gcc (GCC) 11.3.0 Copyright (C) 2021 Free Software Foundation, Inc.
> > This is free software; see the source for copying conditions.  There
> > is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR 
> > PURPOSE.
>
> So you are building the module on target ? If so, that is something we test 
> nightly, and as part of the release builds, so it is known to work for all 
> releases (i.e. we won't release with it broken).
>
> >
> > But I actual believe that I use the same compiler as the one used to build 
> > the kernel.
> > I suspect that the version format from the gcc compiler has changed so the 
> > compare of the versions don't work.
> >
> > The kernel compiling works for an old Yocto kernel 3.19.5  from 2015  with 
> > same makefile and source file.
>
> A kernel of that vintage wouldn't have checks for the compiler.
>
> We'd have to know more about your image, your layers, if kernel-devsrc is 
> installed on target, and if you've done "make scripts prepare"
> before starting to build the module.
>
> Bruce
>
> >
> >
> >
> >
>
>
> --
> - Thou shalt not follow the NULL pointer, for chaos and madness await thee at 
> its end
> - "Use the force Harry" - Gandalf, Star Trek II
>


--
- Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end
- "Use the force Harry" - Gandalf, Star Trek II

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#12227): 
https://lists.yoctoproject.org/g/linux-yocto/message/12227
Mute This Topic: https://lists.yoctoproject.org/mt/97367211/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: 
https://lists.yoctoproject.org/g/linux-yocto/leave/6687884/21656/624485779/xyzzy
 [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [linux-yocto] Can't compile kernel module under kirkstone

2023-03-04 Thread Anders Berndtsson
Hi Bruce,
Thanks, I missed the "make scripts prepare" 8 years has past since I did this 
the last time.
Now I can compile and load the driver but still get the warning.

warning: the compiler differs from the one used to build the kernel
  The kernel was built by: x86_64-poky-linux-gcc (GCC) 11.3.0
  You are using:   gcc (GCC) 11.3.0


So something is not 100% correct.

Kind regards
Anders



-Original Message-
From: linux-yocto@lists.yoctoproject.org  
On Behalf Of Bruce Ashfield
Sent: den 3 mars 2023 19:08
To: Anders Berndtsson 
Cc: linux-yocto@lists.yoctoproject.org
Subject: Re: [linux-yocto] Can't compile kernel module under kirkstone

On Fri, Mar 3, 2023 at 12:23 PM Anders Berndtsson 
 wrote:
>
> Get this message when compiling a kernel module under branch kirkstone 
> and intel-corei7-64
> warning: the compiler differs from the one used to build the kerne
>   The kernel was built by: x86_64-poky-linux-gcc (GCC) 11.3.0
>   You are using:   gcc (GCC) 11.3.0
> cat /proc/version
> Linux version 5.15.85-intel-pk-standard (oe-user@oe-host) 
> (x86_64-poky-linux-gcc (GCC) 11.3.0, GNU ld (GNU Binutils) 
> 2.38.20220708) #1 SMP PREEMPT Wed Jan 11 19:36:47 UTC 2023 gcc 
> --version gcc (GCC) 11.3.0 Copyright (C) 2021 Free Software Foundation, Inc.
> This is free software; see the source for copying conditions.  There 
> is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR 
> PURPOSE.

So you are building the module on target ? If so, that is something we test 
nightly, and as part of the release builds, so it is known to work for all 
releases (i.e. we won't release with it broken).

>
> But I actual believe that I use the same compiler as the one used to build 
> the kernel.
> I suspect that the version format from the gcc compiler has changed so the 
> compare of the versions don't work.
>
> The kernel compiling works for an old Yocto kernel 3.19.5  from 2015  with 
> same makefile and source file.

A kernel of that vintage wouldn't have checks for the compiler.

We'd have to know more about your image, your layers, if kernel-devsrc is 
installed on target, and if you've done "make scripts prepare"
before starting to build the module.

Bruce

>
>
> 
>


--
- Thou shalt not follow the NULL pointer, for chaos and madness await thee at 
its end
- "Use the force Harry" - Gandalf, Star Trek II


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#12213): 
https://lists.yoctoproject.org/g/linux-yocto/message/12213
Mute This Topic: https://lists.yoctoproject.org/mt/97367211/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [linux-yocto] Can't compile kernel module under kirkstone

2023-03-03 Thread Bruce Ashfield
On Fri, Mar 3, 2023 at 12:23 PM Anders Berndtsson
 wrote:
>
> Get this message when compiling a kernel module under branch kirkstone and 
> intel-corei7-64
> warning: the compiler differs from the one used to build the kerne
>   The kernel was built by: x86_64-poky-linux-gcc (GCC) 11.3.0
>   You are using:   gcc (GCC) 11.3.0
> cat /proc/version
> Linux version 5.15.85-intel-pk-standard (oe-user@oe-host) 
> (x86_64-poky-linux-gcc (GCC) 11.3.0, GNU ld (GNU Binutils) 2.38.20220708) #1 
> SMP PREEMPT Wed Jan 11 19:36:47 UTC 2023
> gcc --version
> gcc (GCC) 11.3.0
> Copyright (C) 2021 Free Software Foundation, Inc.
> This is free software; see the source for copying conditions.  There is NO
> warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

So you are building the module on target ? If so, that is something we
test nightly, and as part of the release builds, so it is known to
work for all releases (i.e. we won't release with it broken).

>
> But I actual believe that I use the same compiler as the one used to build 
> the kernel.
> I suspect that the version format from the gcc compiler has changed so the 
> compare of the versions don't work.
>
> The kernel compiling works for an old Yocto kernel 3.19.5  from 2015  with 
> same makefile and source file.

A kernel of that vintage wouldn't have checks for the compiler.

We'd have to know more about your image, your layers, if kernel-devsrc
is installed on target, and if you've done "make scripts prepare"
before starting to build the module.

Bruce

>
>
> 
>


-- 
- Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end
- "Use the force Harry" - Gandalf, Star Trek II

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#12212): 
https://lists.yoctoproject.org/g/linux-yocto/message/12212
Mute This Topic: https://lists.yoctoproject.org/mt/97367211/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: 
https://lists.yoctoproject.org/g/linux-yocto/leave/6687884/21656/624485779/xyzzy
 [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[linux-yocto] Can't compile kernel module under kirkstone

2023-03-03 Thread Anders Berndtsson
*Get this message when compiling a kernel module under branch kirkstone and* 
*intel-corei7-64*
warning: the compiler differs from the one used to build the kerne
The kernel was built by: x86_64-poky-linux-gcc (GCC) 11.3.0
You are using:           gcc (GCC) 11.3.0
*cat /proc/version*
Linux version 5.15.85-intel-pk-standard (oe-user@oe-host) 
(x86_64-poky-linux-gcc (GCC) 11.3.0, GNU ld (GNU Binutils) 2.38.20220708) #1 
SMP PREEMPT Wed Jan 11 19:36:47 UTC 2023
*gcc --version*
gcc (GCC) 11.3.0
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

But I actual believe that I use the same compiler as the one used to build the 
kernel.
I suspect that the version format from the gcc compiler has changed so the 
compare of the versions don't work.

The kernel compiling works for an old Yocto kernel 3.19.5  from 2015  with same 
makefile and source file.

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#12211): 
https://lists.yoctoproject.org/g/linux-yocto/message/12211
Mute This Topic: https://lists.yoctoproject.org/mt/97367211/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-