v5.2.18 dkms fails to build with 5.0 kernel on bionic

Bug #1829248 reported by Trent Nelson
20
This bug affects 3 people
Affects Status Importance Assigned to Milestone
virtualbox (Ubuntu)
Confirmed
Undecided
Unassigned
Bionic
Fix Released
Medium
Connor Kuehl

Bug Description

[Impact]

 * virtualbox-dkms fails to build on 5.0 kernels. This affects Bionic because the Bionic HWE Edge kernels are based on 5.0. virtualbox-dkms cannot be installed successfully since the DKMS module can't be compiled due to API changes introduced between Linux 4.15 and 5.0.

[Test Case]

 * Install the HWE Edge kernel on Bionic:
   - `sudo apt install linux-generic-hwe-18.04-edge`
 * Reboot into the new kernel (you should be on a 5.0 kernel now)
 * Try installing `virtualbox-dkms` (`sudo apt install virtualbox-dkms`)
   - Expected result: package installs successfully, module can be viewed with `sudo dkms status`
   - Actual result: Installation fails due to compilation errors when building the DKMS module.

[Testing]

These steps were performed in an amd64 virtual machine installed from a Bionic cloud image for both the 4.15 kernel that comes with the image as well as a 5.0.0 kernel that is installed from the HWE Edge package.

 * Create a .deb with the .debdiff attached to comment #3
   - `sudo apt build-dep virtualbox` (you will need to uncomment the deb-src lines in /etc/apt/sources.list if you haven't already)
   - `pull-lp-source virtualbox bionic`
   - `patch -p1 < path/to/patch.debdiff`
   - `quilt push -a`
   - `debuild -b -us -uc`
== the step above can be completed just once independently of which kernel you're testing on ==

 * Install `virtualbox-dkms` with apt and confirm it installs properly (only on 4.15; on 5.0, this step should fail)
   - `sudo apt install virtualbox-dkms`
 * Remove `virtualbox-dkms`
   - `sudo apt remove virtualbox-dkms`
 * Install the new .deb prepared in the first step.
 * Confirm that installation succeeded (there would be errors if it didn't.) The module should also be listed when running `sudo dkms status` -- this step should succeed on both 4.15 and 5.0 kernels.

[Regression Potential]

 * These changes are conditionally compiled depending on the kernel version. The only exception to this is the addition of an inlined function for operating on timespec64. That is conditionally compiled based on whether the kernel has timespec64, not necessarily just on the kernel version.

Original bug description follows:
----------------------------------

v5.2.18 dkms fails to build on bionic with the recently released 5.0 kernel from hwe-18.04-edge

I've attached a patch which doesn't seem to not work. It should definitely be reviewed by someone with domain knowledge, though. The problems were all use of interfaces deprecated in 4.0.

Revision history for this message
Trent Nelson (trent-a-b-nelson) wrote :
Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "5.0 kernel build fix" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

tags: added: patch
Connor Kuehl (connork)
Changed in virtualbox (Ubuntu Bionic):
status: New → In Progress
importance: Undecided → Medium
assignee: nobody → Connor Kuehl (connork)
Revision history for this message
Connor Kuehl (connork) wrote :

Attaching debdiff to this comment for SRU consideration into Bionic. Adding SRU information to original bug description.

Thank you for the patch, Trent!

description: updated
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in virtualbox (Ubuntu):
status: New → Confirmed
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Please test proposed package

Hello Trent, or anyone else affected,

Accepted virtualbox into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/virtualbox/5.2.32-dfsg-0~ubuntu18.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in virtualbox (Ubuntu Bionic):
status: In Progress → Fix Committed
tags: added: verification-needed verification-needed-bionic
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Hello Trent, or anyone else affected,

Accepted virtualbox-hwe into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/virtualbox-hwe/5.2.32-dfsg-0~ubuntu18.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Hello Trent, or anyone else affected,

Accepted virtualbox-ext-pack into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/virtualbox-ext-pack/5.2.32-1~ubuntu18.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Hello Trent, or anyone else affected,

Accepted virtualbox-guest-additions-iso into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/virtualbox-guest-additions-iso/5.2.32-1~ubuntu18.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Revision history for this message
Gianfranco Costamagna (costamagnagianfranco) wrote :

works as expected!

tags: added: verification-done verification-done-bionic
removed: verification-needed verification-needed-bionic
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package virtualbox - 5.2.32-dfsg-0~ubuntu18.04.1

---------------
virtualbox (5.2.32-dfsg-0~ubuntu18.04.1) bionic; urgency=medium

  * SRU the latest package for bionic (LP: #1835576, LP: #1829248)
  [ Connor Kuehl ]
  * Fix build for Linux 5.0 (LP: #1835576)
    - debian/patches/ubuntu-0001-linux-5.0-compat.patch
    - debian/patches/ubuntu-0002-linux-5.0-move-ms-remount.patch
    - debian/patches/ubuntu-0003-linux-5.0-make-driver-work-with-Linux-5.0.patch
    - debian/patches/ubuntu-0004-drop-FBINFO_CAN_FORCE_OUTPUT-flag.patch
    - debian/patches/ubuntu-0005-switch-to-drm_get-drm_put-helpers.patch
    - debian/patches/ubuntu-0006-fixup-vboxvideo-module-include.patch
    - debian/patches/ubuntu-0007-update-connector-functions.patch

  [ Gianfranco Costamagna ]
  * Do not apply patches ubuntu-000{1,2,3,4,5,7], because they are included in
    this upstream release
  * New upstream release, update postinst.
  * CVE fixes
    - CVE-2019-2656
    - CVE-2019-2680
    - CVE-2019-2696
    - CVE-2019-2703
    - CVE-2019-2721
    - CVE-2019-2722
    - CVE-2019-2723
    - CVE-2019-2657
    - CVE-2019-2690
    - CVE-2019-2679
    - CVE-2019-2678
    - CVE-2019-2574
  * Drop patches useless with this new upstream release:
    - 18-system-xorg.patch
    - new-gcc.patch
    - kernel-4.18.patch
    - fix-guest-to-host-escape-vulnerability.patch
  * Cherry-pick some fixes from Debian git master branch
    - Enable full hardening
    - automatically detect wsimport from the system
    - bump std-version to 4.3.0
    - Add suid bit to VBoxNetNat to make it work (LP: #1805651)
    - Finally relax dh_strip hack
    - Relax some version constraints, already fullfilled since o-o-stable
    - use cafe instead of beef, to detect if we are inside a VM to fix
      copy-paste.
    - Start VBoxClient too, with the right --vmsvga flag, to fix screen resize
    - Switch to java11, that changed everything (Closes: #920723)
      - add new jaxw dependencies.
    - Switch from iasl to the new acpica-tools name
    - Implement DEB_BUILD_OPTIONS=parallel=n handling during build
      (Closes: #924302)

 -- Gianfranco Costamagna <email address hidden> Thu, 18 Apr 2019 09:30:21 +0200

Changed in virtualbox (Ubuntu Bionic):
status: Fix Committed → Fix Released
Revision history for this message
Andy Whitcroft (apw) wrote : Update Released

The verification of the Stable Release Update for virtualbox has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.