DPDK patches and discussions
 help / color / mirror / Atom feed
From: Hernan Vargas <hernan.vargas@intel.com>
To: dev@dpdk.org, gakhil@marvell.com, trix@redhat.com,
	maxime.coquelin@redhat.com
Cc: nicolas.chautru@intel.com, qi.z.zhang@intel.com,
	Hernan Vargas <hernan.vargas@intel.com>
Subject: [PATCH v1 04/10] baseband/acc: future proof structure comparison
Date: Fri, 30 Aug 2024 13:09:46 -0700	[thread overview]
Message-ID: <20240830200952.182685-5-hernan.vargas@intel.com> (raw)
In-Reply-To: <20240830200952.182685-1-hernan.vargas@intel.com>

Some implementation in the PMD is based on some size assumption from
the bbdev structure, which should use sizeof instead to be more future
proof in case these structures change.

Signed-off-by: Hernan Vargas <hernan.vargas@intel.com>
---
 drivers/baseband/acc/acc_common.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/baseband/acc/acc_common.h b/drivers/baseband/acc/acc_common.h
index 0d1357ace61f..5c5cccf4c9c6 100644
--- a/drivers/baseband/acc/acc_common.h
+++ b/drivers/baseband/acc/acc_common.h
@@ -95,8 +95,8 @@
 #define ACC_COMPANION_PTRS             8
 #define ACC_FCW_VER                    2
 #define ACC_MUX_5GDL_DESC              6
-#define ACC_CMP_ENC_SIZE               20
-#define ACC_CMP_DEC_SIZE               24
+#define ACC_CMP_ENC_SIZE               (sizeof(struct rte_bbdev_op_ldpc_enc) - ACC_ENC_OFFSET)
+#define ACC_CMP_DEC_SIZE               (sizeof(struct rte_bbdev_op_ldpc_dec) - ACC_DEC_OFFSET)
 #define ACC_ENC_OFFSET                (32)
 #define ACC_DEC_OFFSET                (80)
 #define ACC_LIMIT_DL_MUX_BITS          534
-- 
2.37.1


  parent reply	other threads:[~2024-08-30 20:15 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-30 20:09 [PATCH v1 00/10] acc baseband PMD fix and updates for 24.11 Hernan Vargas
2024-08-30 20:09 ` [PATCH v1 01/10] baseband/acc: fix access to deallocated mem Hernan Vargas
2024-09-13 14:49   ` Maxime Coquelin
2024-08-30 20:09 ` [PATCH v1 02/10] baseband/acc: queue allocation refactor Hernan Vargas
2024-08-30 20:09 ` [PATCH v1 03/10] baseband/acc: configure max queues per device Hernan Vargas
2024-08-30 20:09 ` Hernan Vargas [this message]
2024-08-30 20:09 ` [PATCH v1 05/10] baseband/acc: enhance SW ring alignment Hernan Vargas
2024-08-30 20:09 ` [PATCH v1 06/10] baseband/acc: remove soft output bypass Hernan Vargas
2024-08-30 20:09 ` [PATCH v1 07/10] baseband/acc: algorithm tuning for LDPC decoder Hernan Vargas
2024-08-30 20:09 ` [PATCH v1 08/10] baseband/acc: remove check on HARQ memory Hernan Vargas
2024-08-30 20:09 ` [PATCH v1 09/10] baseband/acc: reset ring data valid bit Hernan Vargas
2024-08-30 20:09 ` [PATCH v1 10/10] baseband/acc: cosmetic changes Hernan Vargas
2024-08-30 20:23 ` [PATCH v1 00/10] acc baseband PMD fix and updates for 24.11 Vargas, Hernan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240830200952.182685-5-hernan.vargas@intel.com \
    --to=hernan.vargas@intel.com \
    --cc=dev@dpdk.org \
    --cc=gakhil@marvell.com \
    --cc=maxime.coquelin@redhat.com \
    --cc=nicolas.chautru@intel.com \
    --cc=qi.z.zhang@intel.com \
    --cc=trix@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).