Opened 8 years ago
Closed 7 years ago
#16966 closed defect (fixed)
get_user_pages() interface change backported on OpenSUSE -> fixed in 5.2 and later builds after Nov 3 2017
Reported by: | Dmitri Chubarov | Owned by: | |
---|---|---|---|
Component: | host support | Version: | VirtualBox 5.1.26 |
Keywords: | Cc: | ||
Guest type: | all | Host type: | Linux |
Description
Several changes to the linux kernel memory management interface had been backported on OpenSUSE.
These two patches are
mm/gup: Overload get_user_pages() functions
https://github.com/torvalds/linux/commit/cde70140fed8429acf7a14e2e2cbd3e329036653 and
mm/gup: Remove the macro overload API migration helpers from the get_user*() APIs
https://github.com/torvalds/linux/commit/c12d2da56d0e07d230968ee2305aaa86b93a6832
This leads to the failure of vboxdrv compilation on OpenSUSE Leap 42.3 with the following diagnostics in /var/log/vbox-install.log:
/usr/src/linux-4.4.76-1/include/linux/mm.h:1264:6: note: expected ‘struct vm_area_struct **’ but argument is of type ‘int’ long get_user_pages(unsigned long start, unsigned long nr_pages, ^ /tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c:1117:33: error: too many arguments to function ‘get_user_pages’ papVMAs); /* vmas */ ^ In file included from /tmp/vbox.0/r0drv/linux/the-linux-kernel.h:98:0, from /tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c:31: /usr/src/linux-4.4.76-1/include/linux/mm.h:1264:6: note: declared here long get_user_pages(unsigned long start, unsigned long nr_pages, ^
As one can see the kernel version here is 4.4.76-1, however the get_user_pages() interface looks already has the changes from Ingo Molnar that went into the 4.6.y series.
Attached is the vbox-install.log and the mm.h file provided with the distribution.
Attachments (7)
Change History (26)
by , 8 years ago
by , 8 years ago
Attachment: | memobj-2.patch added |
---|
A quick fix that pushes all linux version checks for new mm/gup code back to 4.4.0
comment:1 by , 8 years ago
Added a patch that seems to fix the immediate issue on OpenSUSE Leap 42.3.
comment:2 by , 8 years ago
Sorry, that fix is not appropriate because it would break vanilla kernels. Any way to detect the specific openSUSE kernels?
comment:3 by , 8 years ago
Could you point me to the browsable Leap 42.3 reopsitory, in particular to the source code of the Leap kernel?
comment:5 by , 8 years ago
In case someone finds it helpful. OpenSUSE developers maintain the kernel tree with their patches at http://kernel.opensuse.org/cgit/kernel and the patches themselves at http://kernel.opensuse.org/cgit/kernel-source. The patches that broke virtual box installation were introduced by Joerg Roedel in December 2016-March 2017.
follow-up: 7 comment:6 by , 8 years ago
Fixed in diff:@68214:68217. These changes will be part of the next maintenance release.
comment:8 by , 8 years ago
Same issue with SuSE Leap 42.3 and VB 5.1.26. Temporary fix was to revert to kernel 4.4.74
comment:9 by , 8 years ago
Just use the most recent 5.1 Guest Additions ISO image from our test builds page.
comment:10 by , 8 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Summary: | get_user_pages() interface change backported on OpenSUSE → get_user_pages() interface change backported on OpenSUSE -> fixed in 5.1.28 |
comment:11 by , 8 years ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
Same probleme with VirtualBox-5.2-5.2.0_118431_openSUSE132-1.x86_64.rpm on opensuse leap 42.3 with kernel 4.4.87-25-default.
Install error 1
make KBUILD_VERBOSE=1 SUBDIRS=/tmp/vbox.0 SRCROOT=/tmp/vbox.0 CONFIG_MODULE_SIG= -C /lib/modules/4.4.79-4-default/build -j8 modules make[1]: warning: -jN forced in submake: disabling jobserver mode. make -C /usr/src/linux-4.4.79-4-obj/x86_64/default KBUILD_SRC=/usr/src/linux-4.4.79-4 \ -f /usr/src/linux-4.4.79-4/Makefile modules 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)
Install error 2
/tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c: In function ‘rtR0MemObjNativeLockUser’: /tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c:1100:33: warning: passing argument 1 of ‘get_user_pages’ makes integer from pointer without a cast [enabled by default] papVMAs); /* vmas */ ^ In file included from /tmp/vbox.0/r0drv/linux/the-linux-kernel.h:98:0, from /tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c:31: /usr/src/linux-4.4.79-4/include/linux/mm.h:1264:6: note: expected ‘long unsigned int’ but argument is of type ‘struct task_struct *’ long get_user_pages(unsigned long start, unsigned long nr_pages, ^ /tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c:1100:33: warning: passing argument 2 of ‘get_user_pages’ makes integer from pointer without a cast [enabled by default] papVMAs); /* vmas */ ^ In file included from /tmp/vbox.0/r0drv/linux/the-linux-kernel.h:98:0, from /tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c:31: /usr/src/linux-4.4.79-4/include/linux/mm.h:1264:6: note: expected ‘long unsigned int’ but argument is of type ‘struct mm_struct *’ long get_user_pages(unsigned long start, unsigned long nr_pages, ^ /tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c:1100:33: warning: passing argument 4 of ‘get_user_pages’ makes pointer from integer without a cast [enabled by default] papVMAs); /* vmas */ ^ In file included from /tmp/vbox.0/r0drv/linux/the-linux-kernel.h:98:0, from /tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c:31: /usr/src/linux-4.4.79-4/include/linux/mm.h:1264:6: note: expected ‘struct page **’ but argument is of type ‘int’ long get_user_pages(unsigned long start, unsigned long nr_pages, ^ /tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c:1100:33: warning: passing argument 5 of ‘get_user_pages’ makes pointer from integer without a cast [enabled by default] papVMAs); /* vmas */ ^ In file included from /tmp/vbox.0/r0drv/linux/the-linux-kernel.h:98:0, from /tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c:31: /usr/src/linux-4.4.79-4/include/linux/mm.h:1264:6: note: expected ‘struct vm_area_struct **’ but argument is of type ‘int’ long get_user_pages(unsigned long start, unsigned long nr_pages, ^ /tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c:1100:33: error: too many arguments to function ‘get_user_pages’ papVMAs); /* vmas */ ^ In file included from /tmp/vbox.0/r0drv/linux/the-linux-kernel.h:98:0, from /tmp/vbox.0/r0drv/linux/memobj-r0drv-linux.c:31: /usr/src/linux-4.4.79-4/include/linux/mm.h:1264:6: note: declared here long get_user_pages(unsigned long start, unsigned long nr_pages, ^
comment:12 by , 8 years ago
Cannot install VirtualBox-5.1-5.1.28_117968_openSUSE132-1.x86_64.rpm on kernel 4.4.87-25-default I must say that every kernel source files are installed and dkms is installed.
by , 7 years ago
Attachment: | VIRTUALBOX_INSTALL_TEST.tar.gz added |
---|
Virtualbox install log for 5.2, 5.1.30, 5.1.28 on kernel 4.4.87-25-default
comment:15 by , 7 years ago
Kernel : ========== Linux Linux 4.4.87-25-default #1 SMP Wed Sep 13 07:19:13 UTC 2017 (3927ef5) x86_64 x86_64 x86_64 GNU/Linux
Install : ========== VirtualBox-5.2-5.2.0_118431_openSUSE132-1.x86_64.rpm
install error : ================
Multiple error of this kind, but nothing else.
make KBUILD_VERBOSE=1 CONFIG_MODULE_SIG= -C /lib/modules/4.4.87-25-default/build SUBDIRS=/tmp/vbox.0 SRCROOT=/tmp/vbox.0 -j8 modules make[1]: warning: -jN forced in submake: disabling jobserver mode. make -C /usr/src/linux-4.4.87-25-obj/x86_64/default KBUILD_SRC=/usr/src/linux-4.4.87-25 \ -f /usr/src/linux-4.4.87-25/Makefile modules
( \ |
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)
lsmod : ======== vboxdrv 516096 3 vboxnetadp,vboxnetflt,vboxpci vboxnetadp 28672 0 vboxnetflt 32768 0 vboxpci 28672 0
Removing VirtualBox-5.2 =========================
Error : ========= depmod: ERROR: fstatat(5, vboxnetadp.ko): No such file or directory depmod: ERROR: fstatat(5, vboxnetflt.ko): No such file or directory depmod: ERROR: fstatat(5, vboxpci.ko): No such file or directory depmod: ERROR: fstatat(5, vboxdrv.ko): No such file or directory
Similar kind of errors for the three version on kernel 4.4.87-25-default
See attachment for virtualbox log.
I will try to install kernel 4.4.90 and give you news.
by , 7 years ago
Attachment: | KERNEL_4_4_92.tar.gz added |
---|
Logs and config files kernel 4.4.92 - Virtualbox 5.2
comment:16 by , 7 years ago
After installing kernel 4.4.92 I installed Virtualbox 5.2 No error during installation. After installing Guest addition no errors on the WINDOWS 10 VM On linux VM, I have an error (xmessage) each time user log on : "VBoxClient: VBoxClient (seamless): failed to start. Stage: Setting guest IRQ filter mask Error: VERR_INTERNAL_ERROR"
See attachements for details.
I you need more ask me.
by , 7 years ago
Attachment: | install_guest_add.tar.gz added |
---|
errors logs when installing guest additions
comment:17 by , 7 years ago
Cannot install module vboxsf when installing guest additions See attachements for details. I you need more ask me.
comment:18 by , 7 years ago
After applying current update to the linux hosts and linux guest vm there is no more alarm when reinstalling guest addition. Every things seems OK.
comment:19 by , 7 years ago
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
Summary: | get_user_pages() interface change backported on OpenSUSE -> fixed in 5.1.28 → get_user_pages() interface change backported on OpenSUSE -> fixed in 5.2 and later builds after Nov 3 2017 |
include/linux/mm.h file provided with OpenSUSE 42.3