[62/83] crypto/bcmfs: move alignment attribute on types

Message ID 1710949096-5786-63-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/crypto/bcmfs/bcmfs_qp.h          | 4 ++--
 drivers/crypto/bcmfs/bcmfs_sym_session.h | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)
  

Patch

diff --git a/drivers/crypto/bcmfs/bcmfs_qp.h b/drivers/crypto/bcmfs/bcmfs_qp.h
index 57fe0a9..42adff9 100644
--- a/drivers/crypto/bcmfs/bcmfs_qp.h
+++ b/drivers/crypto/bcmfs/bcmfs_qp.h
@@ -76,7 +76,7 @@  struct bcmfs_queue {
 	char memz_name[RTE_MEMZONE_NAMESIZE];
 };
 
-struct bcmfs_qp {
+struct __rte_cache_aligned bcmfs_qp {
 	/* Queue-pair ID */
 	uint16_t qpair_id;
 	/* Mapped IO address */
@@ -104,7 +104,7 @@  struct bcmfs_qp {
 	/* a temporary buffer to keep message pointers */
 	struct bcmfs_qp_message *infl_msgs[BCMFS_MAX_REQS_BUFF];
 
-} __rte_cache_aligned;
+};
 
 /* Structure defining h/w queue pair operations */
 struct bcmfs_hw_queue_pair_ops {
diff --git a/drivers/crypto/bcmfs/bcmfs_sym_session.h b/drivers/crypto/bcmfs/bcmfs_sym_session.h
index 4a0a012..12e95f6 100644
--- a/drivers/crypto/bcmfs/bcmfs_sym_session.h
+++ b/drivers/crypto/bcmfs/bcmfs_sym_session.h
@@ -24,7 +24,7 @@  enum bcmfs_sym_chain_order {
 };
 
 /* BCMFS_SYM crypto private session structure */
-struct bcmfs_sym_session {
+struct __rte_cache_aligned bcmfs_sym_session {
 	enum bcmfs_sym_chain_order chain_order;
 
 	/* Cipher Parameters */
@@ -83,7 +83,7 @@  struct bcmfs_sym_session {
 	} aead;
 
 	bool cipher_first;
-} __rte_cache_aligned;
+};
 
 int
 bcmfs_process_crypto_op(struct rte_crypto_op *op,