Skip to content

Conversation

@joe-lawrence
Copy link
Contributor

Initial commit for arm64 unit tests based on v6.17-rc4 kernel and a 6.12.0-125.el10.aarch64 + olddefconfig.

Add a collection of examples/integration-test generated object files to
serve as unit tests.

  $ git describe HEAD
  v6.17-rc4-201-gd69eb204c255

  $ gcc --version
  gcc (GCC) 14.3.1 20250617 (Red Hat 14.3.1-2)

The kernel config was based on:

  - 6.12.0-125.el10.aarch64
  - olddefconfig
  - CONFIG_LIVEPATCH=y

Signed-off-by: Joe Lawrence <joe.lawrence@redhat.com>
Add examples/cmdline.patch objects from UBSAN enabled kernel.

    $ git describe HEAD
    v6.17-rc4-201-gd69eb204c255

    $ gcc --version
    gcc (GCC) 14.3.1 20250617 (Red Hat 14.3.1-2)

The kernel config was based on:

    - 6.12.0-125.el10.aarch64
    - olddefconfig
    - CONFIG_LIVEPATCH=y
    - CONFIG_ARCH_HAS_UBSAN=y
    - CONFIG_UBSAN=y
    - # CONFIG_UBSAN_TRAP is not set
    - CONFIG_CC_HAS_UBSAN_BOUNDS_STRICT=y
    - CONFIG_UBSAN_BOUNDS=y
    - CONFIG_UBSAN_BOUNDS_STRICT=y
    - CONFIG_UBSAN_SHIFT=y
    - CONFIG_UBSAN_DIV_ZERO=y
    - CONFIG_UBSAN_UNREACHABLE=y
    - CONFIG_UBSAN_BOOL=y
    - CONFIG_UBSAN_ENUM=y
    - CONFIG_UBSAN_ALIGNMENT=y
    - # CONFIG_TEST_UBSAN is not set
    - # CONFIG_UBSAN_KVM_EL2 is not set

Signed-off-by: Joe Lawrence <joe.lawrence@redhat.com>
@joe-lawrence
Copy link
Contributor Author

Here's the full kernel config: config.txt

@joe-lawrence
Copy link
Contributor Author

Hi @puranjaymohan, do you see anything missing or awry for an initial unit-test drop? Ideally we commit this, then bump the unit test reference over on dynup/kpatch#1439.

@puranjaymohan
Copy link

Hi @joe-lawrence,

I think we can merge this PR and then bump the reference as you say.

@joe-lawrence
Copy link
Contributor Author

#51 had added two tests to the previous set:

  • syscall - I've included that here
  • mapping - to test "zero-length mappings" - I found that if I reverted ("create-diff-object: Fix mapping symbol handling on aarch64"), the cmdline-patch test then fails, so I think it's already testing for this

I found a few glitches when turning UBSAN configurations on, but at this point I'll file those as bugs after the merge.

@joe-lawrence joe-lawrence merged commit 4ad64a0 into master Sep 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants