aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/generic/hack-4.14/204-module_strip.patch
diff options
context:
space:
mode:
authorStijn Tintel <stijn@linux-ipv6.be>2018-02-08 09:36:38 +0100
committerStijn Tintel <stijn@linux-ipv6.be>2018-02-08 18:43:13 +0100
commit3072908d0d946e38928e477fc6c32b952c7afc22 (patch)
treee50a1c27e1e08c4cb6f3c66d88d66b91b40c3c70 /target/linux/generic/hack-4.14/204-module_strip.patch
parent787326b43e332b378899205294b1d92ea77a45d4 (diff)
downloadupstream-3072908d0d946e38928e477fc6c32b952c7afc22.tar.gz
upstream-3072908d0d946e38928e477fc6c32b952c7afc22.tar.bz2
upstream-3072908d0d946e38928e477fc6c32b952c7afc22.zip
kernel: bump 4.14 to 4.14.18
Refresh patches. Remove upstreamed patches: - apm821xx/010-crypto-gcm-add-GCM-IV-size-constant.patch - backport/040-crypto-fix-typo-in-KPP-dependency-of-CRYPTO_ECDH.patch Remove pending-4.14/650-pppoe_header_pad.patch, it is superseded by upstream commit d32e5740001972c1bb193dd60af02721d047a17e. Update patch that no longer applies: hack/204-module_strip.patch Compile-tested: octeon, x86/64. Runtime-tested: octeon, x86/64. Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
Diffstat (limited to 'target/linux/generic/hack-4.14/204-module_strip.patch')
-rw-r--r--target/linux/generic/hack-4.14/204-module_strip.patch26
1 files changed, 18 insertions, 8 deletions
diff --git a/target/linux/generic/hack-4.14/204-module_strip.patch b/target/linux/generic/hack-4.14/204-module_strip.patch
index 2141cfef92..2cbcf0f72f 100644
--- a/target/linux/generic/hack-4.14/204-module_strip.patch
+++ b/target/linux/generic/hack-4.14/204-module_strip.patch
@@ -98,7 +98,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
--- a/init/Kconfig
+++ b/init/Kconfig
-@@ -1896,6 +1896,13 @@ config TRIM_UNUSED_KSYMS
+@@ -1903,6 +1903,13 @@ config TRIM_UNUSED_KSYMS
If unsure, or if you need to build out-of-tree modules, say N.
@@ -114,7 +114,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
config MODULES_TREE_LOOKUP
--- a/kernel/module.c
+++ b/kernel/module.c
-@@ -2997,9 +2997,11 @@ static struct module *setup_load_info(st
+@@ -3006,9 +3006,11 @@ static struct module *setup_load_info(st
static int check_modinfo(struct module *mod, struct load_info *info, int flags)
{
@@ -127,14 +127,14 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
if (flags & MODULE_INIT_IGNORE_VERMAGIC)
modmagic = NULL;
-@@ -3020,6 +3022,7 @@ static int check_modinfo(struct module *
+@@ -3029,6 +3031,7 @@ static int check_modinfo(struct module *
mod->name);
add_taint_module(mod, TAINT_OOT_MODULE, LOCKDEP_STILL_OK);
}
+#endif
- if (get_modinfo(info, "staging")) {
- add_taint_module(mod, TAINT_CRAP, LOCKDEP_STILL_OK);
+ check_modinfo_retpoline(mod, info);
+
--- a/scripts/mod/modpost.c
+++ b/scripts/mod/modpost.c
@@ -1982,7 +1982,9 @@ static void read_symbols(char *modname)
@@ -158,7 +158,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
buf_printf(b, "\n");
buf_printf(b, "__visible struct module __this_module\n");
buf_printf(b, "__attribute__((section(\".gnu.linkonce.this_module\"))) = {\n");
-@@ -2161,16 +2165,20 @@ static void add_header(struct buffer *b,
+@@ -2161,24 +2165,30 @@ static void add_header(struct buffer *b,
static void add_intree_flag(struct buffer *b, int is_intree)
{
@@ -168,6 +168,16 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
+#endif
}
+ /* Cannot check for assembler */
+ static void add_retpoline(struct buffer *b)
+ {
++#ifndef CONFIG_MODULE_STRIPPED
+ buf_printf(b, "\n#ifdef RETPOLINE\n");
+ buf_printf(b, "MODULE_INFO(retpoline, \"Y\");\n");
+ buf_printf(b, "#endif\n");
++#endif
+ }
+
static void add_staging_flag(struct buffer *b, const char *name)
{
+#ifndef CONFIG_MODULE_STRIPPED
@@ -179,7 +189,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
}
/**
-@@ -2269,11 +2277,13 @@ static void add_depends(struct buffer *b
+@@ -2277,11 +2287,13 @@ static void add_depends(struct buffer *b
static void add_srcversion(struct buffer *b, struct module *mod)
{
@@ -193,7 +203,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
}
static void write_if_changed(struct buffer *b, const char *fname)
-@@ -2509,7 +2519,9 @@ int main(int argc, char **argv)
+@@ -2518,7 +2530,9 @@ int main(int argc, char **argv)
add_staging_flag(&buf, mod->name);
err |= add_versions(&buf, mod);
add_depends(&buf, mod, modules);