UB Sanitizer report:
lib/dp-packet.h:587:22: runtime error: member access within misaligned
address 0x000001ecde10 for type 'struct dp_packet', which requires 64
byte alignment
#0 in dp_packet_set_base lib/dp-packet.h:587
#1 in dp_packet_use__ lib/dp-packet.c:46
#2 in dp_packet_use lib/dp-packet.c:60
#3 in dp_packet_init lib/dp-packet.c:126
#4 in dp_packet_new lib/dp-packet.c:150
[...]
Signed-off-by: Mike Pattrick <[email protected]>
---
lib/dp-packet.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/lib/dp-packet.c b/lib/dp-packet.c
index 61e405460..ae8ab5800 100644
--- a/lib/dp-packet.c
+++ b/lib/dp-packet.c
@@ -146,7 +146,11 @@ dp_packet_uninit(struct dp_packet *b)
struct dp_packet *
dp_packet_new(size_t size)
{
+#ifdef DPDK_NETDEV
+ struct dp_packet *b = xmalloc_cacheline(sizeof *b);
+#else
struct dp_packet *b = xmalloc(sizeof *b);
+#endif
dp_packet_init(b, size);
return b;
}
--
2.31.1
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev