OSDN Git Service
(root)
/
tomoyo
/
tomoyo-test1.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7b88552
)
ASoC: amd: acp: use devm_kcalloc() instead of devm_kzalloc()
author
ye xingchen
<ye.xingchen@zte.com.cn>
Fri, 16 Sep 2022 06:19:06 +0000
(06:19 +0000)
committer
Mark Brown
<broonie@kernel.org>
Mon, 19 Sep 2022 16:52:37 +0000
(17:52 +0100)
Use 2-factor multiplication argument form devm_kcalloc() instead
of devm_kzalloc().
Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn>
Link:
https://lore.kernel.org/r/20220916061906.152434-1-ye.xingchen@zte.com.cn
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/amd/acp/acp-pci.c
patch
|
blob
|
history
diff --git
a/sound/soc/amd/acp/acp-pci.c
b/sound/soc/amd/acp/acp-pci.c
index
ef2ce08
..
a0c84cd
100644
(file)
--- a/
sound/soc/amd/acp/acp-pci.c
+++ b/
sound/soc/amd/acp/acp-pci.c
@@
-107,7
+107,7
@@
static int acp_pci_probe(struct pci_dev *pci, const struct pci_device_id *pci_id
goto unregister_dmic_dev;
}
- res = devm_k
zalloc(&pci->dev, sizeof(struct resource) * num_res
, GFP_KERNEL);
+ res = devm_k
calloc(&pci->dev, num_res, sizeof(struct resource)
, GFP_KERNEL);
if (!res) {
ret = -ENOMEM;
goto unregister_dmic_dev;