IPMMU-VMSA: Delete an error message for a failed memory allocation in ipmmu_probe()
Subsystems (2)
PATCH 1/1 IPMMU-VMSA: Delete an error message for a failed memory allocation in ipmmu_probe()
From: Markus Elfring <[email protected]>
Date: Fri, 19 Jan 2018 22:22:38 +0100
Omit an extra message for a memory allocation failure in this function.
This issue was detected by using the Coccinelle software.
Signed-off-by Markus Elfring <[email protected]>
--- drivers/iommu/ipmmu-vmsa.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/iommu/ipmmu-vmsa.c +1 -3
@@ -949,10 +949,8 @@ static int ipmmu_probe(struct platform_device *pdev)int ret; mmu =devm_kzalloc (&pdev->dev,sizeof (*mmu),GFP_KERNEL ); -if (!mmu) { -dev_err (&pdev->dev,"cannot allocate device data\n" ); +if (!mmu)return -ENOMEM ; - } mmu->dev = &pdev->dev; mmu->num_utlbs =32 ;
Signature · 1 line
2.15.1