[PATCH v2 38/83] ml/cnxk: move alignment attribute on types
Tyler Retzlaff
roretzla at linux.microsoft.com
Mon Apr 15 22:04:00 CEST 2024
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 at linux.microsoft.com>
Acked-by: Morten Brørup <mb at smartsharesystems.com>
---
drivers/ml/cnxk/cnxk_ml_ops.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/ml/cnxk/cnxk_ml_ops.h b/drivers/ml/cnxk/cnxk_ml_ops.h
index 7b49793..e348cc4 100644
--- a/drivers/ml/cnxk/cnxk_ml_ops.h
+++ b/drivers/ml/cnxk/cnxk_ml_ops.h
@@ -19,7 +19,7 @@
#endif
/* Request structure */
-struct cnxk_ml_req {
+struct __rte_aligned(ROC_ALIGN) cnxk_ml_req {
/* Device specific request */
union {
/* CN10K */
@@ -39,7 +39,7 @@ struct cnxk_ml_req {
/* Op */
struct rte_ml_op *op;
-} __rte_aligned(ROC_ALIGN);
+};
/* Request queue */
struct cnxk_ml_queue {
--
1.8.3.1
More information about the dev
mailing list