linux4.9: really fix build w/ gcc-9.1.0

Signed-off-by: Jürgen Buchmüller <pullmoll@t-online.de>
This commit is contained in:
Jürgen Buchmüller 2019-06-29 13:14:20 +02:00
parent 2b7732ad3c
commit 087de63cd7
No known key found for this signature in database
GPG key ID: DE55AD8DBEBB4EE8
2 changed files with 19 additions and 1 deletions

View file

@ -0,0 +1,19 @@
diff --git a/include/linux/module.h b/include/linux/module.h
index 8fa38d3e7538..f5bc4c046461 100644
--- a/include/linux/module.h
+++ b/include/linux/module.h
@@ -129,13 +129,13 @@ extern void cleanup_module(void);
#define module_init(initfn) \
static inline initcall_t __maybe_unused __inittest(void) \
{ return initfn; } \
- int init_module(void) __attribute__((alias(#initfn)));
+ int init_module(void) __attribute__((__copy__(initfn))) __attribute__((alias(#initfn)));
/* This is only required if you want to be unloadable. */
#define module_exit(exitfn) \
static inline exitcall_t __maybe_unused __exittest(void) \
{ return exitfn; } \
- void cleanup_module(void) __attribute__((alias(#exitfn)));
+ void cleanup_module(void) __attribute__((__copy__(exitfn))) __attribute__((alias(#exitfn)));
#endif

View file

@ -85,7 +85,6 @@ do_build() {
fi
export LDFLAGS=
make ARCH=$arch ${_version} ${_cross} ${makejobs} prepare
vsed -i Makefile -e "/KBUILD_CFLAGS *:=/s/:= /:= -Wno-error /"
make ARCH=$arch ${_version} ${_cross} ${makejobs} ${_args}
}
do_install() {