]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
icp: fix rodata being marked as text in x86 Asm code
authorAlexander Lobakin <alobakin@pm.me>
Sun, 16 Oct 2022 21:23:44 +0000 (23:23 +0200)
committerTony Hutter <hutter2@llnl.gov>
Wed, 30 Nov 2022 18:15:58 +0000 (10:15 -0800)
commit33bc03dea7bc976307ad158bf4240c947700b3c2
treeef5beff8b76e8606b61d0a7382dff8a82d328d22
parentee93cbc9d477d8ce0a6ebffe9a582dbe83144577
icp: fix rodata being marked as text in x86 Asm code

objtool properly complains that it can't decode some of the
instructions from ICP x86 Asm code. As mentioned in the Makefile,
where those object files were excluded from objtool check (but they
can still be visible under IBT and LTO), those are just constants,
not code.
In that case, they must be placed in .rodata, so they won't be
marked as "allocatable, executable" (ax) in EFL headers and this
effectively prevents objtool from trying to decode this data. That
reveals a whole bunch of other issues in ICP Asm code, as previously
objtool was bailing out after that warning message.

Reviewed-by: Attila Fülöp <attila@fueloep.org>
Reviewed-by: Tino Reichardt <milky-zfs@mcmilk.de>
Reviewed-by: Richard Yao <richard.yao@alumni.stonybrook.edu>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Alexander Lobakin <alobakin@pm.me>
Closes #14035

Conflicts:
module/Kbuild.in
module/icp/Makefile.in
module/icp/asm-x86_64/modes/aesni-gcm-x86_64.S
module/icp/asm-x86_64/modes/ghash-x86_64.S