Skip to contentSkip to conversation

cryptodev: Fix build errors with v4.11

RFC In review Daniel Schultz 3 participants 5 messages Jan 5, 2018 – Jan 17, 2018

lore
Share & tools
lore
#0 lore raw

RFC 1/1 cryptodev: Fix build errors with v4.11

Commit message from the included patch:
"Linux kernel has added -Werror=designated-init around 4.11 (c834f0e8a8b) triggering build errors with gcc 5 and 6 (but not with gcc 4)"

Backport from https://github.com/cryptodev-linux/cryptodev-linux
Based on commit f0d69774afb27ffc62bf353465fba145e70cb85a

---
 .../cryptodev/cryptodev-module_1.9.bb              |  1 +
 .../0001-ioctl.c-Fix-build-with-linux-4.13.patch   | 49 ++++++++++++++++++++++
 2 files changed, 50 insertions(+)
 create mode 100644 meta/recipes-kernel/cryptodev/files/0001-ioctl.c-Fix-build-with-linux-4.13.patch
meta/recipes-kernel/cryptodev/cryptodev-module_1.9.bb +1 -0
index 552eb6a..ed6d0ec 100644
@@ -9,6 +9,7 @@ DEPENDS += "cryptodev-linux"
 
 SRC_URI += " \
 file://0001-Disable-installing-header-file-provided-by-another-p.patch \
+file://0001-ioctl.c-Fix-build-with-linux-4.13.patch \
 "
 
 EXTRA_OEMAKE='KERNEL_DIR="${STAGING_KERNEL_DIR}" PREFIX="${D}"'
meta/recipes-kernel/cryptodev/files/0001-ioctl.c-Fix-build-with-linux-4.13.patch new file +49 -0

49 lines not on this page · raw message

Signature · 1 line
2.7.4
#1 lore raw
Quoted 9 lines · Daniel Schultz

Commit message from the included patch:
"Linux kernel has added -Werror=designated-init around 4.11 (c834f0e8a8b)
triggering build errors with gcc 5 and 6 (but not with gcc 4)"

Backport from https://github.com/cryptodev-linux/cryptodev-linux
Based on commit f0d69774afb27ffc62bf353465fba145e70cb85a

I'm a little puzzled. Which release is this against? We're using kernels newer than 4.11 so why aren't things breaking?

Cheers,

Richard

#2 lore raw

Hi,

Quoted 6 lines · Richard Purdie
Quoted 5 lines · Daniel Schultz

Commit message from the included patch:
"Linux kernel has added -Werror=designated-init around 4.11 (c834f0e8a8b)
triggering build errors with gcc 5 and 6 (but not with gcc 4)"

Quoted 6 lines
Quoted 4 lines

Backport from https://github.com/cryptodev-linux/cryptodev-linux
Based on commit f0d69774afb27ffc62bf353465fba145e70cb85a

I'm a little puzzled. Which release is this against? We're using kernels newer than 4.11 so why aren't things breaking?

I use rocko and a v4.14 kernel.

Your right. The kernel patch was accepted in march. I will build again with v4.12 and 13.

Signature · 3 lines
Mit freundlichen Grüßen,
With best regards,
  Daniel Schultz
#3 lore raw

Cryptodev only breaks with 4.13 and 4.14. 4.12 builds successfully with and without this patch.

Daniel

Quoted 20 lines · Daniel Schultz

Hi,

Quoted 6 lines · Richard Purdie
Quoted 5 lines · Daniel Schultz

Commit message from the included patch:
"Linux kernel has added -Werror=designated-init around 4.11 (c834f0e8a8b)
triggering build errors with gcc 5 and 6 (but not with gcc 4)"

Quoted 6 lines
Quoted 4 lines

Backport from https://github.com/cryptodev-linux/cryptodev-linux
Based on commit f0d69774afb27ffc62bf353465fba145e70cb85a

I'm a little puzzled. Which release is this against? We're using kernels newer than 4.11 so why aren't things breaking?

I use rocko and a v4.14 kernel.

Your right. The kernel patch was accepted in march. I will build again with v4.12 and 13.

Signature · 20 lines
Mit freundlichen Grüßen,
With best regards,
  Daniel Schultz

- Entwicklung -
Tel.: 	+49 6131 92 21 457
[email protected]
www.phytec.de

Sie finden uns auch auf: Facebook, LinkedIn, Xing, YouTube

PHYTEC Messtechnik GmbH | Robert-Koch-Str. 39 | 55129 Mainz, Germany
Geschäftsführer: Dipl.-Ing. Michael Mitezki, Dipl.-Ing. Bodo Huber |
Handelsregister Mainz HRB 4656 | Finanzamt Mainz-Mitte | St.Nr. 266500608,
DE 149059855
This E-Mail may contain confidential or privileged information. If you are
not the intended recipient (or have received this E-Mail in error) please
notify the sender immediately and destroy this E-Mail. Any unauthorized
copying, disclosure or distribution of the material in this E-Mail is
strictly forbidden.
Acked-by on v1 1/1
#4 lore raw
In reply to Daniel Schultz
Quoted 81 lines · Daniel Schultz

Commit message from the included patch:
"Linux kernel has added -Werror=designated-init around 4.11 (c834f0e8a8b) triggering build errors with gcc 5 and 6 (but not with gcc 4)"

Backport from https://github.com/cryptodev-linux/cryptodev-linux
Based on commit f0d69774afb27ffc62bf353465fba145e70cb85a

---
  .../cryptodev/cryptodev-module_1.9.bb              |  1 +
  .../0001-ioctl.c-Fix-build-with-linux-4.13.patch   | 49 ++++++++++++++++++++++
  2 files changed, 50 insertions(+)

create mode 100644 meta/recipes-kernel/cryptodev/files/0001-ioctl.c-Fix-build-with-linux-4.13.patch

meta/recipes-kernel/cryptodev/cryptodev-module_1.9.bb +1 -0
index 552eb6a..ed6d0ec 100644
@@ -9,6 +9,7 @@ DEPENDS += "cryptodev-linux"
 
  SRC_URI += " \
  file://0001-Disable-installing-header-file-provided-by-another-p.patch \
+file://0001-ioctl.c-Fix-build-with-linux-4.13.patch \
  "
 
  EXTRA_OEMAKE='KERNEL_DIR="${STAGING_KERNEL_DIR}" PREFIX="${D}"'
meta/recipes-kernel/cryptodev/files/0001-ioctl.c-Fix-build-with-linux-4.13.patch new file +49 -0
new file mode 100644
index 0000000..a41efac
@@ -0,0 +1,49 @@
+From f0d69774afb27ffc62bf353465fba145e70cb85a Mon Sep 17 00:00:00 2001
+From: Ricardo Ribalda Delgado <[email protected]>
+Date: Mon, 4 Sep 2017 11:05:08 +0200
+Subject: [PATCH] ioctl.c: Fix build with linux 4.13
+
+git/ioctl.c:1127:3: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
+   {0, },
+    ^
+note: (near initialization for 'verbosity_ctl_dir[1]')
+git/ioctl.c:1136:3: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
+   {0, },
+    ^
+
+Linux kernel has added -Werror=designated-init around 4.11 (c834f0e8a8b)
+triggering build errors with gcc 5 and 6 (but not with gcc 4)
+
+Upstream-Status: Backport
+
+Signed-off-by: Ricardo Ribalda Delgado <[email protected]>
+Signed-off-by: Cristian Stoica <[email protected]>
+---
+ ioctl.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/ioctl.c b/ioctl.c
+index 0385203..8d4a162 100644
+--- a/ioctl.c
++++ b/ioctl.c
+@@ -1124,7 +1124,7 @@ static struct ctl_table verbosity_ctl_dir[] = {
+ 		.mode           = 0644,
+ 		.proc_handler   = proc_dointvec,
+ 	},
+-	{0, },
++	{},
+ };
+
+ static struct ctl_table verbosity_ctl_root[] = {
+@@ -1133,7 +1133,7 @@ static struct ctl_table verbosity_ctl_root[] = {
+ 		.mode           = 0555,
+ 		.child          = verbosity_ctl_dir,
+ 	},
+-	{0, },
++	{},
+ };
+ static struct ctl_table_header *verbosity_sysctl_header;
+ static int __init init_cryptodev(void)
+--
+2.7.4
+