Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

scsi: ufs: renesas: Fix private allocation

Should use devm_kzalloc() for struct ufs_renesas_priv because the
.initialized should be false as default.

Fixes: d69520288efd ("scsi: ufs: ufs-renesas: Add support for Renesas R-Car UFS controller")
Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Link: https://lore.kernel.org/r/20230803081812.1446282-1-yoshihiro.shimoda.uh@renesas.com
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>

authored by

Yoshihiro Shimoda and committed by
Martin K. Petersen
b6d128f8 41320b18

+1 -1
+1 -1
drivers/ufs/host/ufs-renesas.c
··· 359 359 { 360 360 struct ufs_renesas_priv *priv; 361 361 362 - priv = devm_kmalloc(hba->dev, sizeof(*priv), GFP_KERNEL); 362 + priv = devm_kzalloc(hba->dev, sizeof(*priv), GFP_KERNEL); 363 363 if (!priv) 364 364 return -ENOMEM; 365 365 ufshcd_set_variant(hba, priv);