Page MenuHomeFreeBSD

arm64: Support BTI checking in most of the kernel
ClosedPublic

Authored by andrew on Jun 3 2024, 4:21 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Dec 16, 12:58 PM
Unknown Object (File)
Nov 23 2025, 5:49 AM
Unknown Object (File)
Nov 21 2025, 9:37 AM
Unknown Object (File)
Nov 15 2025, 7:32 AM
Unknown Object (File)
Nov 12 2025, 6:00 PM
Unknown Object (File)
Nov 11 2025, 4:18 AM
Unknown Object (File)
Nov 2 2025, 7:23 AM
Unknown Object (File)
Oct 30 2025, 3:08 AM

Details

Summary

LLD has the -zbti-report=error argument to check if the BTI note is
present when linking. To allow for this to be used when linking the
kernel and modules:

  • Add the BTI note to the remaining assembly files
  • Mark ptrauth.c as protected by BTI
  • Disable -zbti-report for vmm hypervisor switching code as it's not used there.

The linux64 module doesn't build with the flag as it includes vdso code
that doesn't include the note.

Sponsored by: Arm Ltd

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable