crypto: x86 - avoid absolute references
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest13 patches 2 repliesIn review
- v110 patches 2 repliesSuperseded
Changes in v2 from the cover letter
- add missing tags from Thomas Garnier
- simplify AES-NI GCM tail handling and drop an entire permute vector table (patch #2)
- add a couple of patches to switch to local labels, which removes ~1000 useless code symbols (e.g., _loop0, _loop1, _done etc etc) from kallsyms
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/13 | crypto: x86/aegis128 - Use RIP-relative addressingarch/ | +3 | 0 replies | |
| 2/13 | crypto: x86/aesni - Use RIP-relative addressingarch/ arch/ | +8 | 0 replies | |
| 3/13 | crypto: x86/aria - Use RIP-relative addressingarch/ arch/ arch/ | +40 | 0 replies | |
| 4/13 | crypto: x86/camellia - Use RIP-relative addressingarch/ arch/ arch/ | +34 | 0 replies | |
| 5/13 | crypto: x86/cast5 - Use RIP-relative addressingarch/ | +21 | 0 replies | |
| 6/13 | crypto: x86/cast6 - Use RIP-relative addressingarch/ | +18 | 0 replies | |
| 7/13 | crypto: x86/crc32c - Use RIP-relative addressingarch/ | +2 | 0 replies | |
| 8/13 | crypto: x86/des3 - Use RIP-relative addressingarch/ | +64 | 0 replies | |
| 9/13 | crypto: x86/ghash - Use RIP-relative addressingarch/ | +2 | 0 replies | |
| 10/13 | crypto: x86/sha256 - Use RIP-relative addressingarch/ | +12 | 0 replies | |
| 11/13 | crypto: x86/aesni - Use local .L symbols for codearch/ arch/ | +207 | 0 replies | |
| 12/13 | crypto: x86/crc32 - Use local .L symbols for codearch/ arch/ | +41 | 0 replies | |
| 13/13 | crypto: x86/sha - Use local .L symbols for codearch/ arch/ arch/ +4 more | +57 | 0 replies |
Reviews trailers per patch
None of the 13 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.
| Patch | Kees Cook |
|---|---|
| Series | R-b |
| 1/13 | |
| 2/13 | |
| 3/13 | |
| 4/13 | |
| 5/13 | |
| 6/13 | |
| 7/13 | |
| 8/13 | |
| 9/13 | |
| 10/13 | |
| 11/13 | |
| 12/13 | |
| 13/13 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v2 00/13] crypto: x86 - avoid absolute references
This is preparatory work for allowing the x86 kernel to be built as a PIE executable, which relies mostly on RIP-relative symbol references from code, as these don't need to be updated when a binary is loaded at an address different from its link time address.
Most changes are quite straight-forward, i.e., just adding a (%rip) suffix is enough in many cases. However, some are slightly trickier, and need some minor reshuffling of the asm code to get rid of the absolute references in the code.
Tested with CONFIG_CRYPTO_MANAGER_EXTRA_TESTS=y on a x86 CPU that implements AVX, AVX2 and AVX512.
Changes since v1:
- add missing tags from Thomas Garnier
- simplify AES-NI GCM tail handling and drop an entire permute vector table (patch #2)
- add a couple of patches to switch to local labels, which removes ~1000 useless code symbols (e.g., _loop0, _loop1, _done etc etc) from kallsyms
Ard Biesheuvel (13):
crypto: x86/aegis128 - Use RIP-relative addressing
crypto: x86/aesni - Use RIP-relative addressing
crypto: x86/aria - Use RIP-relative addressing
crypto: x86/camellia - Use RIP-relative addressing
crypto: x86/cast5 - Use RIP-relative addressing
crypto: x86/cast6 - Use RIP-relative addressing
crypto: x86/crc32c - Use RIP-relative addressing
crypto: x86/des3 - Use RIP-relative addressing
crypto: x86/ghash - Use RIP-relative addressing
crypto: x86/sha256 - Use RIP-relative addressing
crypto: x86/aesni - Use local .L symbols for code
crypto: x86/crc32 - Use local .L symbols for code
crypto: x86/sha - Use local .L symbols for code
arch/x86/crypto/aegis128-aesni-asm.S | 6 +- arch/x86/crypto/aesni-intel_asm.S | 198 +++++++-------- arch/x86/crypto/aesni-intel_avx-x86_64.S | 254 +++++++++----------- arch/x86/crypto/aria-aesni-avx-asm_64.S | 28 +-- arch/x86/crypto/aria-aesni-avx2-asm_64.S | 28 +-- arch/x86/crypto/aria-gfni-avx512-asm_64.S | 24 +- arch/x86/crypto/camellia-aesni-avx-asm_64.S | 30 +-- arch/x86/crypto/camellia-aesni-avx2-asm_64.S | 30 +-- arch/x86/crypto/camellia-x86_64-asm_64.S | 6 +- arch/x86/crypto/cast5-avx-x86_64-asm_64.S | 38 +-- arch/x86/crypto/cast6-avx-x86_64-asm_64.S | 32 +-- arch/x86/crypto/crc32-pclmul_asm.S | 16 +- arch/x86/crypto/crc32c-pcl-intel-asm_64.S | 70 +++--- arch/x86/crypto/des3_ede-asm_64.S | 96 +++++--- arch/x86/crypto/ghash-clmulni-intel_asm.S | 4 +- arch/x86/crypto/sha1_avx2_x86_64_asm.S | 25 +- arch/x86/crypto/sha256-avx-asm.S | 16 +- arch/x86/crypto/sha256-avx2-asm.S | 54 +++-- arch/x86/crypto/sha256-ssse3-asm.S | 16 +- arch/x86/crypto/sha512-avx-asm.S | 8 +- arch/x86/crypto/sha512-avx2-asm.S | 16 +- arch/x86/crypto/sha512-ssse3-asm.S | 8 +- 22 files changed, 509 insertions(+), 494 deletions(-)
Signature · 1 line
2.39.2