[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <a9fa76b5091f1626fa19e8e5650a95d8b2257eda.1657455515.git.christophe.jaillet@wanadoo.fr>
Date: Sun, 10 Jul 2022 14:19:12 +0200
From: Christophe JAILLET <christophe.jaillet@...adoo.fr>
To: Boris Brezillon <bbrezillon@...nel.org>,
Arnaud Ebalard <arno@...isbad.org>,
Srujana Challa <schalla@...vell.com>,
Herbert Xu <herbert@...dor.apana.org.au>,
"David S. Miller" <davem@...emloft.net>
Cc: linux-kernel@...r.kernel.org, kernel-janitors@...r.kernel.org,
Christophe JAILLET <christophe.jaillet@...adoo.fr>,
linux-crypto@...r.kernel.org
Subject: [PATCH 1/3] crypto: octeontx2: Simplify bitmap declaration
'OTX2_CPT_ENGS_BITMASK_LEN' is only used to allocate a bitmap.
In order to simplify the code, remove OTX2_CPT_ENGS_BITMASK_LEN and use
DECLARE_BITMAP to declare the 'bits' bitmap.
Signed-off-by: Christophe JAILLET <christophe.jaillet@...adoo.fr>
---
drivers/crypto/marvell/octeontx2/otx2_cptpf_ucode.h | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/crypto/marvell/octeontx2/otx2_cptpf_ucode.h b/drivers/crypto/marvell/octeontx2/otx2_cptpf_ucode.h
index e69320a54b5d..7c503e44a286 100644
--- a/drivers/crypto/marvell/octeontx2/otx2_cptpf_ucode.h
+++ b/drivers/crypto/marvell/octeontx2/otx2_cptpf_ucode.h
@@ -26,8 +26,6 @@
/* Maximum number of supported engines/cores on OcteonTX2/CN10K platform */
#define OTX2_CPT_MAX_ENGINES 144
-#define OTX2_CPT_ENGS_BITMASK_LEN BITS_TO_LONGS(OTX2_CPT_MAX_ENGINES)
-
#define OTX2_CPT_UCODE_SZ (64 * 1024)
/* Microcode types */
@@ -48,7 +46,7 @@ enum otx2_cpt_ucode_type {
};
struct otx2_cpt_bitmap {
- unsigned long bits[OTX2_CPT_ENGS_BITMASK_LEN];
+ DECLARE_BITMAP(bits, OTX2_CPT_MAX_ENGINES);
int size;
};
--
2.34.1
Powered by blists - more mailing lists