linux/arch/arm/include
Thomas Weißschuh 8925110928 ARM: clean up the memset64() C wrapper
[ Upstream commit b52343d1cb ]

The current logic to split the 64-bit argument into its 32-bit halves is
byte-order specific and a bit clunky.  Use a union instead which is
easier to read and works in all cases.

GCC still generates the same machine code.

While at it, rename the arguments of the __memset64() prototype to
actually reflect their semantics.

Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Reported-by: Ben Hutchings <ben@decadent.org.uk> # for -stable
Link: https://lore.kernel.org/all/1a11526ae3d8664f705b541b8d6ea57b847b49a8.camel@decadent.org.uk/
Suggested-by: https://lore.kernel.org/all/aZonkWMwpbFhzDJq@casper.infradead.org/ # for -stable
Link: https://lore.kernel.org/all/aZonkWMwpbFhzDJq@casper.infradead.org/
Signed-off-by: Sasha Levin <sashal@kernel.org>
History 2026-04-18 10:33:06 +02:00
..
asm ARM: clean up the memset64() C wrapper 2026-04-18 10:33:06 +02:00
debug ARM: imx: rename DEBUG_IMX21_IMX27_UART to DEBUG_IMX27_UART 2022-01-27 11:04:29 +01:00
uapi/asm ARM development updates for 5.15: 2021-09-09 13:25:49 -07:00