Message ID | 20210531152325.36671-1-wander@redhat.com (mailing list archive) |
---|---|
State | Accepted |
Commit | b0f6c9ac8088a01cd9b6bfba8ede22f1bd0ff72f |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | netpoll: don't require irqs disabled in rt kernels | expand |
Context | Check | Description |
---|---|---|
netdev/cover_letter | success | Link |
netdev/fixes_present | success | Link |
netdev/patch_count | success | Link |
netdev/tree_selection | success | Guessed tree name to be net-next |
netdev/subject_prefix | warning | Target tree name not specified in the subject |
netdev/cc_maintainers | success | CCed 6 of 6 maintainers |
netdev/source_inline | success | Was 0 now: 0 |
netdev/verify_signedoff | success | Link |
netdev/module_param | success | Was 0 now: 0 |
netdev/build_32bit | success | Errors and warnings before: 2 this patch: 2 |
netdev/kdoc | success | Errors and warnings before: 0 this patch: 0 |
netdev/verify_fixes | success | Link |
netdev/checkpatch | success | total: 0 errors, 0 warnings, 0 checks, 16 lines checked |
netdev/build_allmodconfig_warn | success | Errors and warnings before: 2 this patch: 2 |
netdev/header_inline | success | Link |
Hello: This patch was applied to netdev/net-next.git (refs/heads/master): On Mon, 31 May 2021 12:23:23 -0300 you wrote: > From: Wander Lairson Costa <wander@redhat.com> > > write_msg(netconsole.c:836) calls netpoll_send_udp after a call to > spin_lock_irqsave, which normally disables interrupts; but in PREEMPT_RT > this call just locks an rt_mutex without disabling irqs. In this case, > netpoll_send_udp is called with interrupts enabled. > > [...] Here is the summary with links: - netpoll: don't require irqs disabled in rt kernels https://git.kernel.org/netdev/net-next/c/b0f6c9ac8088 You are awesome, thank you! -- Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html
diff --git a/net/core/netpoll.c b/net/core/netpoll.c index c310c7c1cef7..0a6b04714558 100644 --- a/net/core/netpoll.c +++ b/net/core/netpoll.c @@ -36,6 +36,7 @@ #include <net/ip6_checksum.h> #include <asm/unaligned.h> #include <trace/events/napi.h> +#include <linux/kconfig.h> /* * We maintain a small pool of fully-sized skbs, to make sure the @@ -389,7 +390,8 @@ void netpoll_send_udp(struct netpoll *np, const char *msg, int len) static atomic_t ip_ident; struct ipv6hdr *ip6h; - WARN_ON_ONCE(!irqs_disabled()); + if (!IS_ENABLED(CONFIG_PREEMPT_RT)) + WARN_ON_ONCE(!irqs_disabled()); udp_len = len + sizeof(*udph); if (np->ipv6)