DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] kni: reduce interface name size
@ 2019-11-15 11:41 Michael Pfeiffer
  2019-11-15 12:30 ` Igor Ryzhov
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Michael Pfeiffer @ 2019-11-15 11:41 UTC (permalink / raw)
  To: ferruh.yigit; +Cc: dev, Michael Pfeiffer

The name in rte_kni_device_info is passed to the kernel, which allows
interface names with at most 16 bytes (IFNAMSIZ). rte_kni_alloc with a
longer name currently trigger a kernel BUG in alloc_netdev_mqs in
net/core/dev.c. Reduce RTE_KNI_NAMESIZE to prevent this situation.

Signed-off-by: Michael Pfeiffer <michael.pfeiffer@tu-ilmenau.de>
---
 lib/librte_eal/linux/eal/include/rte_kni_common.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_eal/linux/eal/include/rte_kni_common.h b/lib/librte_eal/linux/eal/include/rte_kni_common.h
index 46f75a710..59339271b 100644
--- a/lib/librte_eal/linux/eal/include/rte_kni_common.h
+++ b/lib/librte_eal/linux/eal/include/rte_kni_common.h
@@ -18,7 +18,7 @@
 /**
  * KNI name is part of memzone name.
  */
-#define RTE_KNI_NAMESIZE 32
+#define RTE_KNI_NAMESIZE 16
 
 #define RTE_CACHE_LINE_MIN_SIZE 64
 
-- 
2.20.1


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

end of thread, other threads:[~2019-11-19 21:02 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-15 11:41 [dpdk-dev] [PATCH] kni: reduce interface name size Michael Pfeiffer
2019-11-15 12:30 ` Igor Ryzhov
2019-11-15 12:43   ` Ferruh Yigit
2019-11-15 12:43   ` Michael Pfeiffer
2019-11-15 12:49     ` Ferruh Yigit
2019-11-15 12:52       ` Michael Pfeiffer
2019-11-15 13:03 ` [dpdk-dev] [PATCH v2] " Michael Pfeiffer
2019-11-15 13:30   ` Ferruh Yigit
2019-11-19 21:02     ` David Marchand
2019-11-15 16:23 ` [dpdk-dev] [PATCH] " Stephen Hemminger
2019-11-19 12:13   ` Ferruh Yigit
2019-11-19 20:58     ` David Marchand

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).