[PATCH v1 07/25] net/ntnic: apply packing to the structure
Oleksandr Kolomeiets
okl-plv at napatech.com
Wed Apr 30 15:48:19 CEST 2025
The structure virtq_desc should not contain any paddings,
so it has been wrapped with __rte_packed_begin and __rte_packed_end macros.
Signed-off-by: Oleksandr Kolomeiets <okl-plv at napatech.com>
---
drivers/net/ntnic/include/ntnic_virt_queue.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/ntnic/include/ntnic_virt_queue.h b/drivers/net/ntnic/include/ntnic_virt_queue.h
index b95efabf97..072365c946 100644
--- a/drivers/net/ntnic/include/ntnic_virt_queue.h
+++ b/drivers/net/ntnic/include/ntnic_virt_queue.h
@@ -34,7 +34,7 @@ struct nthw_virt_queue;
/*
* Split Ring virtq Descriptor
*/
-struct __rte_aligned(8) virtq_desc {
+struct __rte_packed_begin virtq_desc {
/* Address (guest-physical). */
uint64_t addr;
/* Length. */
@@ -43,7 +43,7 @@ struct __rte_aligned(8) virtq_desc {
uint16_t flags;
/* Next field if flags & NEXT */
uint16_t next;
-};
+} __rte_packed_end;
/*
--
2.47.1
More information about the dev
mailing list