knot: drop kru.inc.c static_assert that requires lock-free 16-bit atomics#29572
Merged
Conversation
Contributor
Author
salzmdan
reviewed
May 28, 2026
Contributor
Author
|
will merge this in 1-2 days if no objections |
Contributor
|
We would prefer a patch that would disable this static assert. We have already decided to disable this assertion in future versions, and the only reason it is still included is out of concern for performance. |
Contributor
Author
|
Will spin-up a patch like that. |
commodo
added a commit
to commodo/packages
that referenced
this pull request
May 29, 2026
…mics src/knot/modules/rrl/kru.inc.c contains static_assert(ATOMIC_CHAR16_T_LOCK_FREE == 2, "insufficient atomics"); which fails at compile time on ARMv5 (e.g. arm926ej-s) and any other target whose toolchain does not advertise lock-free 16-bit atomics, breaking the RRL (Rate Limiting) module build for those arches. Per the upstream maintainer's review of PR openwrt#29572, this static assertion is intended to be dropped in a future release and is only still present out of concern for performance, not correctness — they recommended a patch over a Makefile-level RRL disable. Replace the previous `--with-module-rrl=no` approach for pre-ARMv7 ARM targets with the upstream-recommended source patch so RRL keeps working on every target the rest of knot already builds for. Bump PKG_RELEASE for the patch swap. Suggested-by: Daniel Salzman <daniel.salzman@nic.cz> Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
…mics The RRL module's kru.inc.c has a `static_assert(ATOMIC_CHAR16_T_LOCK_FREE == 2, ...)` that breaks the build on any target whose toolchain does not advertise lock-free 16-bit atomics (e.g. ARMv5 arm926ej-s). Upstream considers the assertion non-essential and plans to drop it; they recommended a patch over a Makefile-level RRL disable. Bump PKG_RELEASE for the patch swap. Suggested-by: Daniel Salzman <daniel.salzman@nic.cz> Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
Cover each user-facing subpackage with a real functional check instead of relying solely on the CI's generic --version probe: - knot: knotc conf-check on a minimal YAML server config - knot-dig: kdig -h (CLI parser smoke check) - knot-host: khost -h - knot-nsupdate: feed 'quit' through the REPL - knot-zonecheck: validate a minimal example.com zone file end to end - knot-keymgr: initialise a KASP DB in a temp directory knot-libs, knot-libzscanner, and knot-tests are library/harness subpackages; the generic ELF/SONAME checks already cover them. Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
📦 Package Details
Maintainer: : @salzmdan , @Payne-X6
Description:
The RRL (Rate Limiting) module's kru.inc.c contains a static assertion
that ATOMIC_CHAR16_T_LOCK_FREE == 2, requiring lock-free 16-bit atomic
operations. ARMv5 processors like arm926ej-s provide no hardware
atomic primitives, causing the assertion to fail at compile time.
Detect pre-ARMv7 ARM targets by checking for the absence of armv7/armv8
in TARGET_CFLAGS and disable the RRL module for those builds.
🧪 Run Testing Details
✅ Formalities