Opened 5 years ago
Last modified 5 years ago
#19145 closed defect
linux: kernel 5.5-rc1/rc2 - we need changes — at Version 4
Reported by: | Frank Batschulat (Oracle) | Owned by: | Frank Batschulat (Oracle) |
---|---|---|---|
Component: | other | Version: | VirtualBox 6.0.14 |
Keywords: | linux kernel 5.5 5.5-rc1 5.5-rc2 | Cc: | |
Guest type: | other | Host type: | other |
Description (last modified by )
Compiling trunk against the current new mainline kernel: 5.5-rc1 2019-12-08 https://git.kernel.org/torvalds/t/linux-5.5-rc1.tar.gz fails with the following errors for which we need to make adjustments:
In file included from /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/hgsmi_base.c:26:0: /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vbox_drv.h:101:10: fatal error: drm/drmP.h: No such file or directory #include <drm/drmP.h> ^~~~~~~~~~~~ compilation terminated. make[2]: *** [/home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/hgsmi_base.o] Error 1 make[2]: *** Waiting for unfinished jobs.... /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vbox_fb.c:40:10: fatal error: drm/drmP.h: No such file or directory #include <drm/drmP.h> ^~~~~~~~~~~~ compilation terminated. make[2]: *** [/home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vbox_fb.o] Error 1 In file included from /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vboxvideo_guest.h:33:0, from /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/modesetting.c:26: /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vbox_drv.h:101:10: fatal error: drm/drmP.h: No such file or directory #include <drm/drmP.h> ^~~~~~~~~~~~ compilation terminated. make[2]: *** [/home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/modesetting.o] Error 1 kBuild: Generating Java interface files filesplitter: Out of 323 files: 323 rewritten, 0 unchanged. (/home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/vboxjxpcom-gen/jxpcomgen/java/interfaces) /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vbox_drv.c:35:10: fatal error: drm/drmP.h: No such file or directory #include <drm/drmP.h> ^~~~~~~~~~~~ compilation terminated. make[2]: *** [/home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vbox_drv.o] Error 1 make[1]: *** [/home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod] Error 2 make: *** [vboxvideo] Error 2 kmk: *** [/home/ws/vbtrunk/trunk/src/VBox/Additions/linux/Makefile.kmk:354: /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_site_ws_linux-5.5-rc1_mod.run] Error 2 kmk: *** Waiting for unfinished jobs....
That header file does not exist anymore:
root@lserver:/site/ws/linux-5.5-rc1# pwd /site/ws/linux-5.5-rc1 root@lserver:/site/ws/linux-5.5-rc1# find . -name drmP.h -ls root@lserver:/site/ws/linux-5.5-rc1#
but was in the past:
# find /usr -name drmP.h -ls 269962 4 -rw-r--r-- 1 root root 3474 Mär 4 2019 /usr/src/linux-headers-5.0.0-27/include/drm/drmP.h 1933958 4 -rw-r--r-- 1 root root 3474 Mär 4 2019 /usr/src/linux-headers-5.0.0-36/include/drm/drmP.h 2257654 12 -rw-r--r-- 1 root root 11103 Jan 28 2018 /usr/src/linux-headers-4.15.0-72/include/drm/drmP.h 2292256 4 -rw-r--r-- 1 root root 3474 Mär 4 2019 /usr/src/linux-headers-5.0.0-37/include/drm/drmP.h
and was still present in 5.4.1 and 5.4.2:
root@lserver:/site/ws/linux-5.4.1# find . -name drmP.h -ls 3243422 4 -rw-rw-r-- 1 root root 3121 Nov 29 10:10 ./include/drm/drmP.h # pwd /site/ws/linux-5.4.2 root@lserver:/site/ws/linux-5.4.2# find . -name drmP.h -ls 3337858 4 -rw-rw-r-- 1 root root 3121 Dez 4 22:31 ./include/drm/drmP.h
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=71866a56bc7594068d894bacd9ac957878c6816a
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0005cbda438fa846650ae52ce693eeaff6d16b92
[v3,06/12] drm: remove include of drmP.h from bridge/dw_hdmi.h
https://lore.kernel.org/patchwork/patch/1030070/
[v4,4/8] drm/hisilicon/kirin: prepare for drmP.h removal from drm_modeset_helper.h
https://lore.kernel.org/patchwork/patch/1031546/
https://lkml.org/lkml/2019/1/26/140
and more, see:
https://www.collabora.com/news-and-blog/news-and-events/linux-kernel-5.4.html
also affected is 5.5.0-rc2 https://git.kernel.org/torvalds/t/linux-5.5-rc2.tar.gz
Change History (5)
comment:1 by , 5 years ago
Owner: | set to |
---|---|
Status: | new → accepted |
comment:2 by , 5 years ago
comment:3 by , 5 years ago
if we disable that header file:
$ svn diff Index: src/VBox/Additions/linux/drm/vbox_drv.c =================================================================== --- src/VBox/Additions/linux/drm/vbox_drv.c (revision 135411) +++ src/VBox/Additions/linux/drm/vbox_drv.c (working copy) @@ -36,7 +36,10 @@ #include <linux/console.h> #include <linux/vt_kern.h> +#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 5, 0) #include <drm/drmP.h> +#endif + #include <drm/drm_crtc_helper.h> #include "vbox_drv.h" Index: src/VBox/Additions/linux/drm/vbox_drv.h =================================================================== --- src/VBox/Additions/linux/drm/vbox_drv.h (revision 135411) +++ src/VBox/Additions/linux/drm/vbox_drv.h (working copy) @@ -103,7 +103,9 @@ #define S64_MIN ((s64)(-S64_MAX - 1)) #endif +#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 5, 0) #include <drm/drmP.h> +#endif #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 11, 0) || defined(RHEL_75) #include <drm/drm_encoder.h> #endif Index: src/VBox/Additions/linux/drm/vbox_fb.c =================================================================== --- src/VBox/Additions/linux/drm/vbox_fb.c (revision 135411) +++ src/VBox/Additions/linux/drm/vbox_fb.c (working copy) @@ -42,7 +42,9 @@ #include <linux/fb.h> #include <linux/init.h> +#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 5, 0) #include <drm/drmP.h> +#endif #include <drm/drm_crtc.h> #include <drm/drm_fb_helper.h> #include <drm/drm_crtc_helper.h>
We get a lot of follow up compilation errors we have to fix for the LINUX version macros:
/home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vbox_drv.c:35:5: error: "LINUX_VERSION_CODE" is not defined, evaluates to 0 [-Werror=undef] #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 5, 0) ^~~~~~~~~~~~~~~~~~ /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vbox_drv.c:35:26: error: "KERNEL_VERSION" is not defined, evaluates to 0 [-Werror=undef] #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 5, 0) ^~~~~~~~~~~~~~ /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vbox_drv.c:35:40: error: missing binary operator before token "(" #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 5, 0) ^ kBuild: xpidl XPCOM - /home/ws/vbtrunk/trunk/src/libs/xpcom18a4/xpcom/base/nsIConsoleService.idl kBuild: xpidl XPCOM - /home/ws/vbtrunk/trunk/src/libs/xpcom18a4/xpcom/base/nsIErrorService.idl /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vbox_fb.c:40:5: error: "LINUX_VERSION_CODE" is not defined, evaluates to 0 [-Werror=undef] #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 5, 0) ^~~~~~~~~~~~~~~~~~ /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vbox_fb.c:40:26: error: "KERNEL_VERSION" is not defined, evaluates to 0 [-Werror=undef] #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 5, 0) ^~~~~~~~~~~~~~ /home/ws/vbtrunk/trunk/out/linux.amd64/debug/obj/tstvboxvideo-src_mod/vbox_fb.c:40:40: error: missing binary operator before token "(" #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 5, 0) ^
$ svn diff Index: src/VBox/Additions/linux/drm/vbox_drv.c =================================================================== --- src/VBox/Additions/linux/drm/vbox_drv.c (revision 135411) +++ src/VBox/Additions/linux/drm/vbox_drv.c (working copy) @@ -36,11 +36,12 @@ #include <linux/console.h> #include <linux/vt_kern.h> +#include "vbox_drv.h" + +#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 5, 0) #include <drm/drmP.h> +#endif #include <drm/drm_crtc_helper.h> - -#include "vbox_drv.h" - #if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 1, 0) || defined(RHEL_81) #include <drm/drm_probe_helper.h> #endif Index: src/VBox/Additions/linux/drm/vbox_drv.h =================================================================== --- src/VBox/Additions/linux/drm/vbox_drv.h (revision 135411) +++ src/VBox/Additions/linux/drm/vbox_drv.h (working copy) @@ -103,7 +103,9 @@ #define S64_MIN ((s64)(-S64_MAX - 1)) #endif +#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 5, 0) #include <drm/drmP.h> +#endif #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 11, 0) || defined(RHEL_75) #include <drm/drm_encoder.h> #endif Index: src/VBox/Additions/linux/drm/vbox_fb.c =================================================================== --- src/VBox/Additions/linux/drm/vbox_fb.c (revision 135411) +++ src/VBox/Additions/linux/drm/vbox_fb.c (working copy) @@ -42,12 +42,15 @@ #include <linux/fb.h> #include <linux/init.h> +#include "vbox_drv.h" + +#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 5, 0) #include <drm/drmP.h> +#endif #include <drm/drm_crtc.h> #include <drm/drm_fb_helper.h> #include <drm/drm_crtc_helper.h> -#include "vbox_drv.h" #include <VBoxVideo.h> #if LINUX_VERSION_CODE < KERNEL_VERSION(4, 7, 0) && !defined(RHEL_74)
And then we get to the real errors we have to fix after disabling the use of drmP.h:
see atatched file errors-1.txt
https://www.virtualbox.org/attachment/ticket/19145/errors-1.txt
by , 5 years ago
Attachment: | errors-1.txt added |
---|
comment:4 by , 5 years ago
Description: | modified (diff) |
---|---|
Keywords: | 5.5-rc2 added |
Summary: | linux: kernel 5.5-rc1 - we need changes → linux: kernel 5.5-rc1/rc2 - we need changes |
These are going to be our inspection targets: