[PATCH v2 0/2] arm64: modules: Reject loading of malformed modules

Ard Biesheuvel ardb at kernel.org
Mon Sep 29 09:10:49 PDT 2025


On Mon, 22 Sept 2025 at 15:04, Adrian Barnaś <abarnas at google.com> wrote:
>
> Hi all,
>
> Here is version two of the patches I previously posted here:
>
>   v1: https://lore.kernel.org/all/20250919122321.946462-1-abarnas@google.com/
>
> Changes:
>   * Renamed the parameter `is_module` to `skip_dry_run` in scs_patch()
>   * Moved comments to module_finalize() and improve justification
>   * Instead of rejecting all modules with callback, reject those with cb
>     pointing outside core kernel text
>   * Replace -EPERM to -ENOEXEC when rejecting modules with incorrect cb
>   * Fix missing return in apply_alternatives_module() placeholder
>
> Best regards
> Adrian
>
> Cc: Catalin Marinas <catalin.marinas at arm.com>
> Cc: Will Deacon <will at kernel.org>
> Cc: Ard Biesheuvel <ardb at kernel.org>
> Cc: Dylan Hatch <dylanbhatch at google.com>
> Cc: Mark Rutland <mark.rutland at arm.com>
>
> Adrian Barnaś (2):
>   arch: arm64: Fail module loading if dynamic SCS patching fails
>   arch: arm64: Reject modules with internal alternative callbacks
>

Reviewed-by: Ard Biesheuvel <ardb at kernel.org>



More information about the linux-arm-kernel mailing list