Package: blktap-dkms
Version: 2.0.93-0.6
Severity: normal
Tags: patch
User: ubuntu-de...@lists.ubuntu.com
Usertags: origin-ubuntu yakkety ubuntu-patch

Dear Maintainer,

With later compilers a missmatch between the block_device_operations release
operations definition and the signature of the implementation triggers a build
failure.

We are using the attached patch to resolve this in Ubuntu:
    
  * d/p/follow-block_device_operations-release-return-void.patch -- follow
    upstream interface changes in block_device_operations.

Thanks.

-apw

-- System Information:
Debian Release: stretch/sid
  APT prefers yakkety
  APT policy: (500, 'yakkety')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.4.0-25-generic (SMP w/4 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
diff -Nru blktap-dkms-2.0.93/debian/patches/follow-block_device_operations-release-return-void.patch blktap-dkms-2.0.93/debian/patches/follow-block_device_operations-release-return-void.patch
--- blktap-dkms-2.0.93/debian/patches/follow-block_device_operations-release-return-void.patch	1970-01-01 01:00:00.000000000 +0100
+++ blktap-dkms-2.0.93/debian/patches/follow-block_device_operations-release-return-void.patch	2016-07-05 12:52:56.000000000 +0100
@@ -0,0 +1,40 @@
+Description: follow block_device_operations release return void
+ The return from block_device_operations release became void in 3.10
+ we are now failing to build due due to missmatches of these operations.
+Author: Andy Whitcroft <a...@ubuntu.com>
+---
+
+Index: blktap-dkms-2.0.93/device.c
+===================================================================
+--- blktap-dkms-2.0.93.orig/device.c
++++ blktap-dkms-2.0.93/device.c
+@@ -27,6 +27,7 @@
+ #include <linux/log2.h>
+ #include <scsi/scsi.h>
+ #include <scsi/scsi_ioctl.h>
++#include <linux/version.h>
+ 
+ #include "blktap.h"
+ 
+@@ -50,7 +51,11 @@ blktap_device_open(struct block_device *
+ 	return 0;
+ }
+ 
++#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 10, 0)
+ static int
++#else
++void
++#endif
+ blktap_device_release(struct gendisk *disk, fmode_t mode)
+ {
+ 	struct blktap_device *tapdev = disk->private_data;
+@@ -64,7 +69,9 @@ blktap_device_release(struct gendisk *di
+ 		blktap_ring_kick_user(tap);
+ 	}
+ 
++#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 10, 0)
+ 	return 0;
++#endif
+ }
+ 
+ static int
diff -Nru blktap-dkms-2.0.93/debian/patches/series blktap-dkms-2.0.93/debian/patches/series
--- blktap-dkms-2.0.93/debian/patches/series	2016-03-05 19:42:57.000000000 +0000
+++ blktap-dkms-2.0.93/debian/patches/series	2016-07-05 12:29:07.000000000 +0100
@@ -4,3 +4,4 @@
 mempool_resize.patch
 disallow_mempools_with_ctor.patch
 use-gfpflags_allow_blocking-when-available.patch
+follow-block_device_operations-release-return-void.patch

Reply via email to