diff options
author | Anuj Mittal <anuj.mittal@intel.com> | 2018-07-22 12:18:57 +0800 |
---|---|---|
committer | Anuj Mittal <anuj.mittal@intel.com> | 2018-07-22 13:05:45 +0800 |
commit | fe3841530e8925f5fa416ea3c3b6010bdca1845e (patch) | |
tree | f5b639b83f10711ba253abdd414745fd5e14e8f9 | |
parent | 631043a1f31cb728ce4dae25aea0ecddbab87573 (diff) | |
download | meta-intel-fe3841530e8925f5fa416ea3c3b6010bdca1845e.tar.gz |
cryptodev-module: fix build with 4.14 kernel
Backport patch to suppress errors because of -Werror=designated-init.
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
-rw-r--r-- | common/recipes-kernel/cryptodev/cryptodev-module/0001-ioctl.c-Fix-build-with-linux-4.13.patch | 51 | ||||
-rw-r--r-- | common/recipes-kernel/cryptodev/cryptodev-module_%.bbappend | 2 |
2 files changed, 53 insertions, 0 deletions
diff --git a/common/recipes-kernel/cryptodev/cryptodev-module/0001-ioctl.c-Fix-build-with-linux-4.13.patch b/common/recipes-kernel/cryptodev/cryptodev-module/0001-ioctl.c-Fix-build-with-linux-4.13.patch new file mode 100644 index 00000000..a013d8d7 --- /dev/null +++ b/common/recipes-kernel/cryptodev/cryptodev-module/0001-ioctl.c-Fix-build-with-linux-4.13.patch | |||
@@ -0,0 +1,51 @@ | |||
1 | From f0d69774afb27ffc62bf353465fba145e70cb85a Mon Sep 17 00:00:00 2001 | ||
2 | From: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com> | ||
3 | Date: Mon, 4 Sep 2017 11:05:08 +0200 | ||
4 | Subject: [PATCH] ioctl.c: Fix build with linux 4.13 | ||
5 | |||
6 | git/ioctl.c:1127:3: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init] | ||
7 | {0, }, | ||
8 | ^ | ||
9 | note: (near initialization for 'verbosity_ctl_dir[1]') | ||
10 | git/ioctl.c:1136:3: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init] | ||
11 | {0, }, | ||
12 | ^ | ||
13 | |||
14 | Linux kernel has added -Werror=designated-init around 4.11 (c834f0e8a8b) | ||
15 | triggering build errors with gcc 5 and 6 (but not with gcc 4) | ||
16 | |||
17 | Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com> | ||
18 | Signed-off-by: Cristian Stoica <cristian.stoica@nxp.com> | ||
19 | |||
20 | Upstream-Status: Backport [https://github.com/cryptodev-linux/cryptodev-linux/commit/f0d69774afb27ffc62bf353465fba145e70cb85a] | ||
21 | |||
22 | Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> | ||
23 | --- | ||
24 | ioctl.c | 4 ++-- | ||
25 | 1 file changed, 2 insertions(+), 2 deletions(-) | ||
26 | |||
27 | diff --git a/ioctl.c b/ioctl.c | ||
28 | index 0385203..8d4a162 100644 | ||
29 | --- a/ioctl.c | ||
30 | +++ b/ioctl.c | ||
31 | @@ -1124,7 +1124,7 @@ static struct ctl_table verbosity_ctl_dir[] = { | ||
32 | .mode = 0644, | ||
33 | .proc_handler = proc_dointvec, | ||
34 | }, | ||
35 | - {0, }, | ||
36 | + {}, | ||
37 | }; | ||
38 | |||
39 | static struct ctl_table verbosity_ctl_root[] = { | ||
40 | @@ -1133,7 +1133,7 @@ static struct ctl_table verbosity_ctl_root[] = { | ||
41 | .mode = 0555, | ||
42 | .child = verbosity_ctl_dir, | ||
43 | }, | ||
44 | - {0, }, | ||
45 | + {}, | ||
46 | }; | ||
47 | static struct ctl_table_header *verbosity_sysctl_header; | ||
48 | static int __init init_cryptodev(void) | ||
49 | -- | ||
50 | 2.17.1 | ||
51 | |||
diff --git a/common/recipes-kernel/cryptodev/cryptodev-module_%.bbappend b/common/recipes-kernel/cryptodev/cryptodev-module_%.bbappend index c59ddb2f..0a449b71 100644 --- a/common/recipes-kernel/cryptodev/cryptodev-module_%.bbappend +++ b/common/recipes-kernel/cryptodev/cryptodev-module_%.bbappend | |||
@@ -1,5 +1,7 @@ | |||
1 | FILESEXTRAPATHS_prepend_intel-x86-common := "${THISDIR}/${PN}:" | 1 | FILESEXTRAPATHS_prepend_intel-x86-common := "${THISDIR}/${PN}:" |
2 | 2 | ||
3 | SRC_URI_append = " file://0001-ioctl.c-Fix-build-with-linux-4.13.patch" | ||
4 | |||
3 | python() { | 5 | python() { |
4 | # When we add more kernels for linux-intel, we may have to add a Version check | 6 | # When we add more kernels for linux-intel, we may have to add a Version check |
5 | if (d.getVar("PREFERRED_PROVIDER_virtual/kernel") == "linux-intel"): | 7 | if (d.getVar("PREFERRED_PROVIDER_virtual/kernel") == "linux-intel"): |