From 4b92b266ca35e19e492586d846801010d82889e67f2993d879cb00e78bf5f18e Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Wed, 17 May 2017 22:20:18 +0000 Subject: [PATCH] - Add vhba-signal.diff so it builds with Linux 4.11 OBS-URL: https://build.opensuse.org/package/show/filesystems/vhba-kmp?expand=0&rev=25 --- vhba-kmp.changes | 5 +++++ vhba-kmp.spec | 5 +++-- vhba-signal.diff | 25 +++++++++++++++++++++++++ 3 files changed, 33 insertions(+), 2 deletions(-) create mode 100644 vhba-signal.diff diff --git a/vhba-kmp.changes b/vhba-kmp.changes index 02bcb8d..f756061 100644 --- a/vhba-kmp.changes +++ b/vhba-kmp.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed May 17 22:20:05 UTC 2017 - jengelh@inai.de + +- Add vhba-signal.diff so it builds with Linux 4.11 + ------------------------------------------------------------------- Mon Feb 6 17:35:38 UTC 2017 - jengelh@inai.de diff --git a/vhba-kmp.spec b/vhba-kmp.spec index 202bf93..cd6d37c 100644 --- a/vhba-kmp.spec +++ b/vhba-kmp.spec @@ -29,11 +29,12 @@ Source: http://downloads.sf.net/cdemu/vhba-module-%version.tar.bz2 Source2: %name-preamble Patch1: vhba-no-werror.diff Patch2: vhba-devname.diff +Patch3: vhba-signal.diff BuildRequires: kernel-syms >= 2.6.20 BuildRequires: modutils BuildRoot: %{_tmppath}/%{name}-%{version}-build -%kernel_module_package -n vhba -p %name-preamble +%{?kernel_module_package:%kernel_module_package -n vhba -p %name-preamble} %description A Linux kernel module implementing a virtual SCSI Host Bus Adapter to @@ -56,7 +57,7 @@ Linux. %prep echo %flavors_to_build %setup -qn vhba-module-%version -%patch -P 1 -P 2 -p1 +%patch -P 1 -P 2 -P 3 -p1 %build for flavor in %flavors_to_build; do diff --git a/vhba-signal.diff b/vhba-signal.diff new file mode 100644 index 0000000..e8afacf --- /dev/null +++ b/vhba-signal.diff @@ -0,0 +1,25 @@ +From: Jan Engelhardt +Date: 2017-05-18 00:18:13.674608963 +0200 + +build: resolve build failure with Linux 4.11+ + +vhba.c:711:13: error: implicit declaration of function 'signal_pending' [-Werror=implicit-function-declaration] + if (signal_pending(current)) { +--- + vhba.c | 3 +++ + 1 file changed, 3 insertions(+) + +Index: vhba-module-20161009/vhba.c +=================================================================== +--- vhba-module-20161009.orig/vhba.c ++++ vhba-module-20161009/vhba.c +@@ -28,6 +28,9 @@ + #include + #include + #include ++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,11,0) ++# include ++#endif + #ifdef CONFIG_COMPAT + #include + #endif