All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [Bug 14856] New: nvidia-driver package fails to build
@ 2022-06-20  9:03 bugzilla
  2022-06-20  9:16 ` [Buildroot] [Bug 14856] " bugzilla
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: bugzilla @ 2022-06-20  9:03 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14856

            Bug ID: 14856
           Summary: nvidia-driver package fails to build
           Product: buildroot
           Version: 2022.05
          Hardware: All
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P5
         Component: Other
          Assignee: unassigned@buildroot.uclibc.org
          Reporter: ian_ormshaw@waters.com
                CC: buildroot@uclibc.org
  Target Milestone: ---

Created attachment 9326
  --> https://bugs.busybox.net/attachment.cgi?id=9326&action=edit
config files

I an trying to build a system with kernel 5.15.44-rt46 to use openCl on an
nvidia graphics card.  If I enable Target packages->Hardware
handling->nvidia-driver I get the following build error:

>>> linux 5.15.44 Installing to images directory
/usr/bin/install -m 0644 -D
/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/linux-5.15.44/arch/x86/boot/bzImage
/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/images/bzImage
touch
/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/linux-5.15.44/.stamp_images_installed
touch
/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/linux-5.15.44/.stamp_installed
>>> nvidia-driver 390.132 Building
>>> nvidia-driver 390.132 Building kernel module(s)
PATH="/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/host/bin:/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/host/sbin:/usr/lib64/ccache:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/ian/bin"
PKG_CONFIG="/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/host/bin/pkg-config"
PKG_CONFIG_SYSROOT_DIR="/" PKG_CONFIG_ALLOW_SYSTEM_CFLAGS=1
PKG_CONFIG_ALLOW_SYSTEM_LIBS=1
PKG_CONFIG_LIBDIR="/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/host/lib/pkgconfig:/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/host/share/pkgconfig"
BR_BINARIES_DIR=/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/images
KCFLAGS=-Wno-attribute-alias /usr/bin/make -j17 -C
/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/linux-5.15.44
HOSTCC="/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/host/bin/ccache
/usr/lib64/ccache/gcc -O2
-I/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/host/include
-L/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/host/lib
-Wl,-rpath,/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/host/lib"
ARCH=x86_64
INSTALL_MOD_PATH=/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/target
CROSS_COMPILE="/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/host/bin/x86_64-WatersAMST-linux-gnu-"
WERROR=0
DEPMOD=/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/host/sbin/depmod
NV_KERNEL_SOURCES="/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/linux-5.15.44"
NV_KERNEL_OUTPUT="/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/linux-5.15.44"
NV_KERNEL_MODULES="nvidia nvidia-modeset nvidia-drm nvidia-uvm"
PWD=/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/nvidia-driver-390.132/kernel
M=/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/nvidia-driver-390.132/kernel
modules
make[2]: Entering directory
'/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/linux-5.15.44'
test -e include/generated/autoconf.h -a -e include/config/auto.conf || (       
        \
echo >&2;                                                       \
echo >&2 "  ERROR: Kernel configuration is invalid.";           \
echo >&2 "         include/generated/autoconf.h or include/config/auto.conf are
missing.";\
echo >&2 "         Run 'make oldconfig && make prepare' on kernel src to fix
it.";      \
echo >&2 ;                                                      \
/bin/false)
/usr/bin/make -f ./scripts/Makefile.build
obj=/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/nvidia-driver-390.132/kernel
\
single-build= \
need-builtin=1 need-modorder=1

Compiler version check failed:

The major and minor number of the compiler used to
compile the kernel:

x86_64-WatersAMST-linux-gnu-gcc.br_real (Buildroot 2022.05) 9.4.0, GNU ld (GNU
Binutils) 2.37

does not match the compiler used here:

x86_64-WatersAMST-linux-gnu-gcc.br_real (Buildroot 2022.05) 9.4.0
Copyright (C) 2019 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.


It is recommended to set the CC environment variable
to the compiler that was used to compile the kernel.

The compiler version check can be disabled by setting
the IGNORE_CC_MISMATCH environment variable to "1".
However, mixing compiler versions between the kernel
and kernel modules can result in subtle bugs that are
difficult to diagnose.

*** Failed CC version check. Bailing out! ***

make[3]: ***
[/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/nvidia-driver-390.132/kernel/Kbuild:189:
cc_version_check] Error 1
make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile:1868:
/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/nvidia-driver-390.132/kernel]
Error 2
make[2]: Leaving directory
'/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/linux-5.15.44'
make[1]: *** [package/pkg-generic.mk:294:
/home/ian/build/amst-hiwire-linux-8009b251-x86_64/buildroot/build/nvidia-driver-390.132/.stamp_built]
Error 2
make[1]: Leaving directory
'/home/ian/projects/amst-hiwire-linux/source/buildroot'
make: *** [Makefile:616: buildroot] Error 2

My development system is Fedora 36 GNU/Linux 5.18.5-200.fc36.x86_64

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] [Bug 14856] nvidia-driver package fails to build
  2022-06-20  9:03 [Buildroot] [Bug 14856] New: nvidia-driver package fails to build bugzilla
@ 2022-06-20  9:16 ` bugzilla
  2022-06-20 13:47 ` bugzilla
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: bugzilla @ 2022-06-20  9:16 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14856

--- Comment #1 from Dr I J Ormshaw <ian_ormshaw@waters.com> ---
I get the same issue with gcc 9, 10, and 11

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] [Bug 14856] nvidia-driver package fails to build
  2022-06-20  9:03 [Buildroot] [Bug 14856] New: nvidia-driver package fails to build bugzilla
  2022-06-20  9:16 ` [Buildroot] [Bug 14856] " bugzilla
@ 2022-06-20 13:47 ` bugzilla
  2022-06-20 14:17 ` bugzilla
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: bugzilla @ 2022-06-20 13:47 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14856

--- Comment #2 from Dr I J Ormshaw <ian_ormshaw@waters.com> ---
Created attachment 9331
  --> https://bugs.busybox.net/attachment.cgi?id=9331&action=edit
Fedora 35 build log

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] [Bug 14856] nvidia-driver package fails to build
  2022-06-20  9:03 [Buildroot] [Bug 14856] New: nvidia-driver package fails to build bugzilla
  2022-06-20  9:16 ` [Buildroot] [Bug 14856] " bugzilla
  2022-06-20 13:47 ` bugzilla
@ 2022-06-20 14:17 ` bugzilla
  2022-06-20 17:32 ` bugzilla
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: bugzilla @ 2022-06-20 14:17 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14856

--- Comment #3 from Vincent Fazio <vfazio@xes-inc.com> ---
Pretty sure the CC error may be addressed by
https://patchwork.ozlabs.org/project/buildroot/patch/20211104141910.1840914-1-vfazio@xes-inc.com/

version 390.151 has been released which adds support up to 5.17rc, the 390.132
package I think only technically supports through 5.4

I can resubmit my patch with the version bump and kick off a build to make sure
it at least compiles OK but I don't have the bandwidth to do actual hardware
testing at the moment.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] [Bug 14856] nvidia-driver package fails to build
  2022-06-20  9:03 [Buildroot] [Bug 14856] New: nvidia-driver package fails to build bugzilla
                   ` (2 preceding siblings ...)
  2022-06-20 14:17 ` bugzilla
@ 2022-06-20 17:32 ` bugzilla
  2022-06-21  7:30 ` bugzilla
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: bugzilla @ 2022-06-20 17:32 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14856

--- Comment #4 from Vincent Fazio <vfazio@xes-inc.com> ---
hopefully fixed by
https://patchwork.ozlabs.org/project/buildroot/patch/20220620170940.513445-1-vfazio@xes-inc.com/

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] [Bug 14856] nvidia-driver package fails to build
  2022-06-20  9:03 [Buildroot] [Bug 14856] New: nvidia-driver package fails to build bugzilla
                   ` (3 preceding siblings ...)
  2022-06-20 17:32 ` bugzilla
@ 2022-06-21  7:30 ` bugzilla
  2022-06-21  8:43 ` bugzilla
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: bugzilla @ 2022-06-21  7:30 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14856

--- Comment #5 from Dr I J Ormshaw <ian_ormshaw@waters.com> ---
I am still not able to compile the drivers.  It would appear from
https://gist.github.com/joanbm/144a965c36fc1dc0d1f1b9be3438a368.  That the
patch you have applied only works for 5.10 -> 5.13 and the build breaks again
from 5.14 on.

In file included from
../nvidia-driver-390.144/kernel/common/inc/os-interface.h:27,
                 from ../nvidia-driver-390.144/kernel/nvidia/nv-procfs.c:14:
../../host/lib/gcc/x86_64-WatersAMST-linux-gnu/11.3.0/include/stdarg.h:52:
note: this is the location of the previous definition
   52 | #define va_copy(d,s)    __builtin_va_copy(d,s)
      | 
../nvidia-driver-390.144/kernel/nvidia-drm/nvidia-drm-drv.c: In function
‘nv_drm_register_drm_device’:
../nvidia-driver-390.144/kernel/nvidia-drm/nvidia-drm-drv.c:814:10: error:
‘struct drm_device’ has no member named ‘pdev’; did you mean ‘dev’?
  814 |     dev->pdev = pdev;
      |          ^~~~
      |          dev
make[3]: *** [scripts/Makefile.build:288:
/home/ian/build/amst-hiwire-linux-9297fa84-x86_64/buildroot/build/nvidia-driver-390.144/kernel/nvidia-drm/nvidia-drm-drv.o]
Error 1
../nvidia-driver-390.144/kernel/nvidia/nvlink_linux.c: In function
‘nvlink_sleep’:
../nvidia-driver-390.144/kernel/nvidia/nvlink_linux.c:600:18: error: ‘struct
task_struct’ has no member named ‘state’; did you mean ‘__state’?
  600 |         current->state = TASK_INTERRUPTIBLE;
      |                  ^~~~~
      |                  __state
make[3]: *** [scripts/Makefile.build:288:
/home/ian/build/amst-hiwire-linux-9297fa84-x86_64/buildroot/build/nvidia-driver-390.144/kernel/nvidia/nvlink_linux.o]
Error 1
make[2]: *** [Makefile:1868:
/home/ian/build/amst-hiwire-linux-9297fa84-x86_64/buildroot/build/nvidia-driver-390.144/kernel]
Error 2
make[2]: Leaving directory
'/home/ian/build/amst-hiwire-linux-9297fa84-x86_64/buildroot/build/linux-5.15.44'
make[1]: *** [package/pkg-generic.mk:294:
/home/ian/build/amst-hiwire-linux-9297fa84-x86_64/buildroot/build/nvidia-driver-390.144/.stamp_built]
Error 2
make[1]: Leaving directory
'/home/ian/projects/amst-hiwire-linux/source/buildroot'
make: *** [Makefile:616: buildroot] Error 2

The no cc check patch works as expected on Fedora 36

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] [Bug 14856] nvidia-driver package fails to build
  2022-06-20  9:03 [Buildroot] [Bug 14856] New: nvidia-driver package fails to build bugzilla
                   ` (4 preceding siblings ...)
  2022-06-21  7:30 ` bugzilla
@ 2022-06-21  8:43 ` bugzilla
  2022-06-21 12:02 ` bugzilla
  2022-06-21 12:43 ` bugzilla
  7 siblings, 0 replies; 9+ messages in thread
From: bugzilla @ 2022-06-21  8:43 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14856

--- Comment #6 from Dr I J Ormshaw <ian_ormshaw@waters.com> ---
Created attachment 9336
  --> https://bugs.busybox.net/attachment.cgi?id=9336&action=edit
source tree patch

I've applied this patch to the source tree and it now build for me on my
system.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] [Bug 14856] nvidia-driver package fails to build
  2022-06-20  9:03 [Buildroot] [Bug 14856] New: nvidia-driver package fails to build bugzilla
                   ` (5 preceding siblings ...)
  2022-06-21  8:43 ` bugzilla
@ 2022-06-21 12:02 ` bugzilla
  2022-06-21 12:43 ` bugzilla
  7 siblings, 0 replies; 9+ messages in thread
From: bugzilla @ 2022-06-21 12:02 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14856

--- Comment #7 from Vincent Fazio <vfazio@xes-inc.com> ---
I've submitted
https://patchwork.ozlabs.org/project/buildroot/list/?series=305651

Which uses the upstream 390.151 package. I was able to successfully compile the
driver using the vanilla 5.17 kernel

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] [Bug 14856] nvidia-driver package fails to build
  2022-06-20  9:03 [Buildroot] [Bug 14856] New: nvidia-driver package fails to build bugzilla
                   ` (6 preceding siblings ...)
  2022-06-21 12:02 ` bugzilla
@ 2022-06-21 12:43 ` bugzilla
  7 siblings, 0 replies; 9+ messages in thread
From: bugzilla @ 2022-06-21 12:43 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14856

--- Comment #8 from Dr I J Ormshaw <ian_ormshaw@waters.com> ---
Thanks,

Compiles with my realtime 5.15 kernel too.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2022-06-21 12:44 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-20  9:03 [Buildroot] [Bug 14856] New: nvidia-driver package fails to build bugzilla
2022-06-20  9:16 ` [Buildroot] [Bug 14856] " bugzilla
2022-06-20 13:47 ` bugzilla
2022-06-20 14:17 ` bugzilla
2022-06-20 17:32 ` bugzilla
2022-06-21  7:30 ` bugzilla
2022-06-21  8:43 ` bugzilla
2022-06-21 12:02 ` bugzilla
2022-06-21 12:43 ` bugzilla

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.