ceph-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] Simplify net_dbg_ratelimited() dummy
@ 2024-02-28 14:05 Geert Uytterhoeven
  2024-02-28 14:28 ` Alex Elder
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Geert Uytterhoeven @ 2024-02-28 14:05 UTC (permalink / raw)
  To: Chris Down, Petr Mladek, Greg Kroah-Hartman, Andy Shevchenko,
	Jessica Yu, Steven Rostedt, John Ogness, Sergey Senozhatsky,
	Jason Baron, Jim Cromie, Ilya Dryomov, Xiubo Li, Jeff Layton
  Cc: linux-kernel, ceph-devel, Geert Uytterhoeven

There is no need to wrap calls to the no_printk() helper inside an
always-false check, as no_printk() already does that internally.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 include/linux/net.h | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/include/linux/net.h b/include/linux/net.h
index c9b4a63791a45948..15df6d5f27a7badc 100644
--- a/include/linux/net.h
+++ b/include/linux/net.h
@@ -299,10 +299,7 @@ do {									\
 	net_ratelimited_function(pr_debug, fmt, ##__VA_ARGS__)
 #else
 #define net_dbg_ratelimited(fmt, ...)				\
-	do {							\
-		if (0)						\
-			no_printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__); \
-	} while (0)
+	no_printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__)
 #endif
 
 #define net_get_random_once(buf, nbytes)			\
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-03-01  0:40 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-28 14:05 [PATCH net-next] Simplify net_dbg_ratelimited() dummy Geert Uytterhoeven
2024-02-28 14:28 ` Alex Elder
2024-02-28 17:42 ` Andy Shevchenko
2024-03-01  0:40 ` Chris Down

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).