[PATCH 10/31] net/stack: manager: ratelimit printk when dropping buffers

Jean-Baptiste Tr├ędez jean-baptiste.tredez at alstefgroup.com
Tue May 11 18:05:14 CEST 2021


From: Gilles Chanteperdrix <gilles.chanteperdrix at xenomai.org>

Signed-off-by: Philippe Gerum <rpm at xenomai.org>
---
 kernel/drivers/net/stack/stack_mgr.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/drivers/net/stack/stack_mgr.c b/kernel/drivers/net/stack/stack_mgr.c
index a7e22458a..482f665f2 100644
--- a/kernel/drivers/net/stack/stack_mgr.c
+++ b/kernel/drivers/net/stack/stack_mgr.c
@@ -111,7 +111,7 @@ void rtnetif_rx(struct rtskb *skb)
 	RTNET_ASSERT(skb->rtdev != NULL, return;);
 
 	if (unlikely(rtskb_fifo_insert_inirq(&rx.fifo, skb) < 0)) {
-		rtdm_printk("RTnet: dropping packet in %s()\n", __FUNCTION__);
+		rtdm_printk_ratelimited("RTnet: dropping packet in %s()\n", __FUNCTION__);
 		kfree_rtskb(skb);
 	}
 }
-- 
2.17.1




More information about the Xenomai mailing list