[v2,30/83] net/softnic: move alignment attribute on types

Message ID 1713211485-9021-31-git-send-email-roretzla@linux.microsoft.com (mailing list archive)
State Accepted
Delegated to: David Marchand
Series move alignment attribute on types |


Context Check Description
ci/checkpatch success coding style OK

Commit Message

Tyler Retzlaff April 15, 2024, 8:03 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>
Acked-by: Morten Brørup <mb@smartsharesystems.com>
 drivers/net/softnic/rte_eth_softnic_internals.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)


diff --git a/drivers/net/softnic/rte_eth_softnic_internals.h b/drivers/net/softnic/rte_eth_softnic_internals.h
index a1c2309..d3975da 100644
--- a/drivers/net/softnic/rte_eth_softnic_internals.h
+++ b/drivers/net/softnic/rte_eth_softnic_internals.h
@@ -123,7 +123,7 @@  struct softnic_thread {
  * Data plane threads: context
-struct softnic_thread_data {
+struct __rte_cache_aligned softnic_thread_data {
 	struct rte_swx_pipeline *p[THREAD_PIPELINES_MAX];
 	uint32_t n_pipelines;
@@ -132,7 +132,7 @@  struct softnic_thread_data {
 	uint64_t timer_period; /* Measured in CPU cycles. */
 	uint64_t time_next;
 	uint64_t iter;
-} __rte_cache_aligned;
  * PMD Internals