diff mbox series

[1/2] crypto: hisilicon/qm - remove sizeof(char)

Message ID 20250503-hisilicon_qm-v1-1-d4ebc242bc8a@ethancedwards.com
State New
Headers show
Series crypto: hisilicon/qm - memory allocation cleanups | expand

Commit Message

Ethan Carter Edwards May 3, 2025, 8:21 p.m. UTC
`sizeof(char)` evaluates to 1. Remove the churn.

Signed-off-by: Ethan Carter Edwards <ethan@ethancedwards.com>
---
 drivers/crypto/hisilicon/qm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/crypto/hisilicon/qm.c b/drivers/crypto/hisilicon/qm.c
index d3f5d108b898bb5fa6ef901070e9e97b02afb29a..80d57f0dbf26e2902e01103b0a705234009161ee 100644
--- a/drivers/crypto/hisilicon/qm.c
+++ b/drivers/crypto/hisilicon/qm.c
@@ -862,7 +862,7 @@  int hisi_qm_set_algs(struct hisi_qm *qm, u64 alg_msk, const struct qm_dev_alg *d
 		return -EINVAL;
 	}
 
-	algs = devm_kzalloc(dev, QM_DEV_ALG_MAX_LEN * sizeof(char), GFP_KERNEL);
+	algs = devm_kzalloc(dev, QM_DEV_ALG_MAX_LEN, GFP_KERNEL);
 	if (!algs)
 		return -ENOMEM;