summaryrefslogtreecommitdiff
path: root/drivers/mmc
diff options
context:
space:
mode:
authorRiyan Dhiman <riyandhiman14@gmail.com>2024-09-01 23:03:09 +0530
committerUlf Hansson <ulf.hansson@linaro.org>2024-09-03 14:31:18 +0200
commitd2253bfa830e907eddad13d9de99d7b6df8585a1 (patch)
treee5112c71352a5840c413be6ed39ff2b6b3d58ccd /drivers/mmc
parent03117a4934d6ea3cc9c84baf80c05322485a2b5a (diff)
downloadlwn-d2253bfa830e907eddad13d9de99d7b6df8585a1.tar.gz
lwn-d2253bfa830e907eddad13d9de99d7b6df8585a1.zip
mmc: core: Calculate size from pointer
Calculate the size from pointer instead of struct to adhere to linux kernel coding style. Issue reported by checkpatch. This commit has no functional changes. Signed-off-by: Riyan Dhiman <riyandhiman14@gmail.com> Link: https://lore.kernel.org/r/20240901173309.7124-1-riyandhiman14@gmail.com Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Diffstat (limited to 'drivers/mmc')
-rw-r--r--drivers/mmc/core/block.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mmc/core/block.c b/drivers/mmc/core/block.c
index cc7318089cf2..2ff053f2be11 100644
--- a/drivers/mmc/core/block.c
+++ b/drivers/mmc/core/block.c
@@ -2530,7 +2530,7 @@ static struct mmc_blk_data *mmc_blk_alloc_req(struct mmc_card *card,
return ERR_PTR(devidx);
}
- md = kzalloc(sizeof(struct mmc_blk_data), GFP_KERNEL);
+ md = kzalloc(sizeof(*md), GFP_KERNEL);
if (!md) {
ret = -ENOMEM;
goto out;