linux-arch.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] kbuild: provide include/asm/asm-prototypes.h for ARM
@ 2016-11-22 11:05 Arnd Bergmann
  2016-11-22 16:34 ` Nicolas Pitre
  0 siblings, 1 reply; 106+ messages in thread
From: Arnd Bergmann @ 2016-11-22 11:05 UTC (permalink / raw)
  To: Russell King
  Cc: Uwe Kleine-König, Nicolas Pitre, linux-arm-kernel,
	Nicholas Piggin, viro, linux-kbuild, linux-arch, regressions,
	Arnd Bergmann, linux-kernel

This adds an asm/asm-prototypes.h header for ARM to fix the broken symbol
versioning for symbols exported from assembler files.

I couldn't find the correct prototypes for the compiler builtins,
so I went with the fake 'void f(void)' prototypes that we had
before, restoring the state before they were moved.

Originally I assumed that the problem was just a harmless warning
in unusual configurations, but as Uwe found, we actually need this
to load most modules when symbol versioning is enabled, as it is
in many distro kernels.

Cc: Uwe Kleine-König <uwe@kleine-koenig.org>
Fixes: 4dd1837d7589 ("arm: move exports to definitions")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
Compared to the earlier version, I dropped the changes to the
csumpartial files, which now get handled correctly by Kbuild
even when the export comes from a macro, and I also dropped the
changes to the bitops files, which were already fixed in a
patch from Nico.

The patch applies cleanly on top of the rmk/fixes tree but has
no effect there, as it also needs 4efca4ed05cb ("kbuild: modversions
for EXPORT_SYMBOL() for asm") and cc6acc11cad1 ("kbuild: be more
careful about matching preprocessed asm ___EXPORT_SYMBOL").

With the combination of rmk/fixes, torvalds/master and these two
patches, symbol versioning works again on ARM. As it is still
broken on almost all other architectures (powerpc is fixed,
x86 has a patch), I wonder if we should make CONFIG_MODVERSIONS
as broken for everything else.
---
 arch/arm/include/asm/asm-prototypes.h | 34 ++++++++++++++++++++++++++++++++++
 1 file changed, 34 insertions(+)
 create mode 100644 arch/arm/include/asm/asm-prototypes.h

diff --git a/arch/arm/include/asm/asm-prototypes.h b/arch/arm/include/asm/asm-prototypes.h
new file mode 100644
index 000000000000..04e5616a7b15
--- /dev/null
+++ b/arch/arm/include/asm/asm-prototypes.h
@@ -0,0 +1,34 @@
+#include <linux/arm-smccc.h>
+#include <linux/bitops.h>
+#include <linux/ftrace.h>
+#include <linux/io.h>
+#include <linux/platform_data/asoc-imx-ssi.h>
+#include <linux/string.h>
+#include <linux/uaccess.h>
+
+#include <asm/checksum.h>
+#include <asm/div64.h>
+#include <asm/memory.h>
+
+extern void __aeabi_idivmod(void);
+extern void __aeabi_idiv(void);
+extern void __aeabi_lasr(void);
+extern void __aeabi_llsl(void);
+extern void __aeabi_llsr(void);
+extern void __aeabi_lmul(void);
+extern void __aeabi_uidivmod(void);
+extern void __aeabi_uidiv(void);
+extern void __aeabi_ulcmp(void);
+
+extern void __ashldi3(void);
+extern void __ashrdi3(void);
+extern void __bswapdi2(void);
+extern void __bswapsi2(void);
+extern void __divsi3(void);
+extern void __do_div64(void);
+extern void __lshrdi3(void);
+extern void __modsi3(void);
+extern void __muldi3(void);
+extern void __ucmpdi2(void);
+extern void __udivsi3(void);
+extern void __umodsi3(void);
-- 
2.9.0

^ permalink raw reply related	[flat|nested] 106+ messages in thread

end of thread, other threads:[~2016-12-18 15:08 UTC | newest]

Thread overview: 106+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20161017065131.GA27863@angband.pl>
2016-10-17  6:59 ` [GIT PULL] kbuild changes for v4.9-rc1 Nicholas Piggin
2016-10-17  6:59   ` Nicholas Piggin
2016-10-17 10:01   ` Adam Borowski
2016-10-17 10:01     ` Adam Borowski
2016-10-17 11:12     ` Alexey Dobriyan
2016-10-17 11:12       ` Alexey Dobriyan
2016-10-17 11:17       ` Geert Uytterhoeven
2016-10-17 11:32         ` Alexey Dobriyan
2016-10-17 11:32           ` Alexey Dobriyan
2016-10-17 12:22     ` Mathieu OTHACEHE
2016-10-18  0:16       ` Adam Borowski
2016-10-18  0:16         ` Adam Borowski
2016-10-18  1:34         ` Nicholas Piggin
2016-10-19 14:38           ` Michal Marek
2016-10-19 14:38             ` Michal Marek
2016-10-20  3:52             ` Nicholas Piggin
2016-10-20  3:52               ` Nicholas Piggin
2016-10-27  8:10               ` Kalle Valo
2016-10-27  8:10                 ` Kalle Valo
2016-10-27 11:15                 ` Nicholas Piggin
2016-10-27 11:15                   ` Nicholas Piggin
2016-10-27 13:14                   ` Kalle Valo
2016-10-27 13:14                     ` Kalle Valo
2016-10-27 13:25                     ` Nicholas Piggin
2016-10-27 13:25                       ` Nicholas Piggin
2016-10-30 10:51                 ` Thorsten Leemhuis
2016-10-30 10:51                   ` Thorsten Leemhuis
2016-11-01 15:48           ` Michal Marek
2016-11-01 15:48             ` Michal Marek
2016-11-02 12:11             ` Adam Borowski
2016-11-02 12:11               ` Adam Borowski
2016-11-02 12:14               ` [PATCH] kbuild: provide include/asm/asm-prototypes.h for x86 Adam Borowski
2016-11-02 12:14                 ` Adam Borowski
2016-12-16 19:55     ` [GIT PULL] kbuild changes for v4.9-rc1 Jiri Slaby
2016-12-16 19:55       ` Jiri Slaby
2016-12-16 19:57       ` Linus Torvalds
2016-12-17  8:57         ` Jiri Slaby
2016-12-17  8:57           ` Jiri Slaby
2016-12-17  9:33           ` Adam Borowski
2016-12-17  9:33             ` Adam Borowski
2016-12-17 23:59           ` Linus Torvalds
2016-12-17 23:59             ` Linus Torvalds
2016-12-18 10:49             ` Jiri Slaby
2016-12-18 11:03               ` Arend Van Spriel
2016-12-18 11:03                 ` Arend Van Spriel
2016-12-18 13:27                 ` Nikolay Borisov
2016-12-18 13:27                   ` Nikolay Borisov
2016-12-18 14:45                   ` Jiri Slaby
2016-12-18 14:54                     ` Nikolay Borisov
2016-12-18 15:08                       ` Jiri Slaby
2016-10-17 12:26   ` [PATCH] kbuild: provide include/asm/asm-prototypes.h for ARM Arnd Bergmann
2016-10-19 14:52     ` Michal Marek
2016-10-19 14:52       ` Michal Marek
2016-10-19 15:02       ` Arnd Bergmann
2016-10-19 15:02         ` Arnd Bergmann
2016-10-19 15:32         ` Russell King - ARM Linux
2016-10-19 15:32           ` Russell King - ARM Linux
2016-10-20  4:08           ` Nicholas Piggin
2016-10-20 13:17             ` Russell King - ARM Linux
2016-10-20 13:17               ` Russell King - ARM Linux
2016-10-20 14:20               ` Nicholas Piggin
2016-10-20 14:20                 ` Nicholas Piggin
2016-10-20 14:33                 ` Russell King - ARM Linux
2016-10-20 14:33                   ` Russell King - ARM Linux
2016-10-20 14:51                   ` Nicholas Piggin
2016-10-20 14:51                     ` Nicholas Piggin
2016-10-22 19:51                   ` Michal Marek
2016-10-24 15:04             ` Arnd Bergmann
2016-10-24 15:05               ` [PATCH 1/2] " Arnd Bergmann
2016-10-24 15:05                 ` Arnd Bergmann
2016-10-25  8:32                 ` Nicholas Piggin
2016-11-20 13:21                   ` Russell King - ARM Linux
2016-11-20 18:32                     ` Linus Torvalds
2016-11-20 19:12                       ` Russell King - ARM Linux
2016-11-20 19:12                         ` Russell King - ARM Linux
2016-11-21  6:10                         ` Nicholas Piggin
2016-11-21  6:10                           ` Nicholas Piggin
2016-11-21 18:46                 ` Bug#844530: [1/2] " Uwe Kleine-König
2016-11-21 18:46                   ` Uwe Kleine-König
2016-11-21 19:13                   ` Russell King - ARM Linux
2016-11-21 19:13                     ` Russell King - ARM Linux
2016-11-22  1:01                     ` Nicholas Piggin
2016-10-24 15:06               ` [PATCH 2/2, variant A] ARM: add hidden mmioset/mmiocpy prototypes Arnd Bergmann
2016-10-24 15:06                 ` Arnd Bergmann
2016-10-24 15:06               ` [PATCH 2/2, variant B] ARM: move mmiocpy/mmioset exports to io.c Arnd Bergmann
2016-10-24 15:06                 ` Arnd Bergmann
2016-10-20  7:37           ` [PATCH] kbuild: provide include/asm/asm-prototypes.h for ARM Geert Uytterhoeven
2016-10-20  8:20             ` Russell King - ARM Linux
2016-10-20  8:20               ` Russell King - ARM Linux
2016-10-20  8:23               ` Geert Uytterhoeven
2016-10-20  8:23                 ` Geert Uytterhoeven
2016-11-22 11:05 [PATCH 1/2] " Arnd Bergmann
2016-11-22 16:34 ` Nicolas Pitre
2016-11-22 16:34   ` Nicolas Pitre
2016-11-23  0:41   ` Russell King - ARM Linux
2016-11-23  0:41     ` Russell King - ARM Linux
2016-11-23  1:40     ` Nicholas Piggin
2016-11-23  1:04   ` Nicholas Piggin
2016-11-23  1:04     ` Nicholas Piggin
2016-11-23  1:35     ` Nicolas Pitre
2016-11-23  9:33       ` Russell King - ARM Linux
2016-11-23  9:33         ` Russell King - ARM Linux
2016-11-23 10:36         ` Russell King - ARM Linux
2016-11-23 10:36           ` Russell King - ARM Linux
2016-11-27  2:33           ` Nicolas Pitre
2016-11-27  2:33             ` Nicolas Pitre

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).