Replace printk with pr_* macros for kernel compliance#67
Merged
ayourtch merged 1 commit intoayourtch:masterfrom Jan 8, 2026
Merged
Replace printk with pr_* macros for kernel compliance#67ayourtch merged 1 commit intoayourtch:masterfrom
ayourtch merged 1 commit intoayourtch:masterfrom
Conversation
graysky2
added a commit
to graysky2/openwrt
that referenced
this pull request
Jan 3, 2026
Bump to 2025-11-04 snapshot.
Added 100-gcc15-fix.patch which drops __DATE__/__TIME__ usage and provides
a stable fallback ("unknown"). This fixes build failures with GCC 15 and
-Werror=date-time in kernel builds.
Added 101-Replace-printk-with-pr_-macros-for-kernel-compliance.patch
suggested by github copilot to avoid CI build failures. See header for
details. This has been submitted to merge upstream.[1]
% git log --oneline 04923c5..adb2f72
adb2f72e6fb8 get rid of spurious ubsan complaint for nat46_instance_t pairs field
d5f88686a4a8 Add a test harness which boots the kernel under kvm with a custom init which runs the tests
b983bab221f0 nat46-core: Fix FIXMEs about ICMPv6 parameter pointers
1aca482d6917 Add support for ignoring traffic class or TOS translation at the same time
1. ayourtch/nat46#67
Signed-off-by: John Audia <therealgraysky@proton.me>
Owner
|
@angus19 - this change looks sensible to me. what do you think ? |
Contributor
|
@ayourtch LGTM too. Please merge it. Thanks. |
747a32f to
c45c9c7
Compare
Contributor
Author
|
Rebase should be good one/single commit. |
Update all printk() calls to use appropriate pr_* logging macros to comply with modern kernel coding standards and ensure proper log level semantics across the nat46 module. Changes: - nat46-glue.c: Replace printk with pr_err() for errors and pr_info() for informational messages in instance allocation and release functions - nat46-glue.h: Update assert macro to use pr_emerg() instead of printk for critical assertion failures - nat46-module.c: Replace all printk(KERN_INFO ...) and printk() calls with pr_info() for informational messages and pr_err() for error conditions in module initialization, proc filesystem operations, and device management functions - nat46-netdev.c: Replace printk with pr_err() for error conditions (allocation failures, device operations) and pr_info() for informational messages (device creation, destruction, and debug output) This ensures consistent logging behavior, improves compatibility with newer kernel versions, and follows kernel development best practices for message severity classification. Signed-off-by: John Audia <therealgraysky@proton.me>
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.
Update all printk() calls to use appropriate pr_* logging macros to comply with modern kernel coding standards and ensure proper log level semantics across the nat46 module.
Changes:
nat46-glue.c: Replace printk with pr_err() for errors and pr_info() for informational messages in instance allocation and release functions
nat46-glue.h: Update assert macro to use pr_emerg() instead of printk for critical assertion failures
nat46-module.c: Replace all printk(KERN_INFO ...) and printk() calls with pr_info() for informational messages and pr_err() for error conditions in module initialization, proc filesystem operations, and device management functions
nat46-netdev.c: Replace printk with pr_err() for error conditions (allocation failures, device operations) and pr_info() for informational messages (device creation, destruction, and debug output)
This ensures consistent logging behavior, improves compatibility with newer kernel versions, and follows kernel development best practices for message severity classification.