Nicolas Pitre 42f25bddd0 ARM: 8477/1: runtime patch udiv/sdiv instructions into __aeabi_{u}idiv()
The ARM compiler inserts calls to __aeabi_idiv() and
__aeabi_uidiv() when it needs to perform division on signed and
unsigned integers. If a processor has support for the sdiv and
udiv instructions, the kernel may overwrite the beginning of those
functions with those instructions and a "bx lr" to get better
performance.

To ensure that those functions are aligned to a 32-bit word for easier
patching (which might not always be the case in Thumb mode) and that
the two patched instructions end up in the same cache line, a 8-byte
alignment is enforced when ARM_PATCH_IDIV is selected.

This was heavily inspired by a previous patch from Stephen Boyd.

Signed-off-by: Nicolas Pitre <nico@linaro.org>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2015-12-17 10:29:01 +00:00
..
2015-09-11 19:18:28 +01:00
2015-09-22 08:13:42 +01:00
2015-03-25 09:53:43 +01:00
2015-05-20 23:09:51 +02:00
2015-10-26 10:58:26 +00:00
2014-11-21 15:24:50 +00:00
2014-11-21 15:24:50 +00:00
2015-10-03 16:36:45 +01:00
2014-11-21 15:24:50 +00:00
2015-09-11 19:18:28 +01:00
2014-11-21 15:25:02 +00:00
2015-10-27 09:20:50 +09:00
2014-11-21 15:24:50 +00:00
2014-11-21 15:24:50 +00:00
2015-10-03 16:36:45 +01:00
2015-04-16 13:58:29 -05:00