[23/83] net/mvpp2: move alignment attribute on types

Message ID 1710949096-5786-24-git-send-email-roretzla@linux.microsoft.com (mailing list archive)
State Superseded
Delegated to: David Marchand
Headers
Series move alignment attribute on types |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Tyler Retzlaff March 20, 2024, 3:37 p.m. UTC
  Move location of __rte_aligned(a) to new conventional location. The new
placement between {struct,union} and the tag allows the desired
alignment to be imparted on the type regardless of the toolchain being
used for both C and C++. Additionally, it avoids confusion by Doxygen
when generating documentation.

Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 drivers/net/mvpp2/mrvl_ethdev.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
  

Patch

diff --git a/drivers/net/mvpp2/mrvl_ethdev.h b/drivers/net/mvpp2/mrvl_ethdev.h
index 3b69a6e..178b510 100644
--- a/drivers/net/mvpp2/mrvl_ethdev.h
+++ b/drivers/net/mvpp2/mrvl_ethdev.h
@@ -147,10 +147,10 @@  struct mrvl_priv {
 	uint16_t bpool_init_size; /**< Configured BPool size  */
 
 	/** Mapping for DPDK rx queue->(TC, MRVL relative inq) */
-	struct {
+	alignas(RTE_CACHE_LINE_SIZE) struct {
 		uint8_t tc;  /**< Traffic Class */
 		uint8_t inq; /**< Relative in-queue number */
-	} rxq_map[MRVL_PP2_RXQ_MAX] __rte_cache_aligned;
+	} rxq_map[MRVL_PP2_RXQ_MAX];
 
 	/* Configuration data, used sporadically. */
 	uint8_t pp_id;