Thread (2 messages) flat view 2 messages, 2 authors, 2021-03-12
STALE1978d LANDED

Landed in mainline as c8e386683652 on 2021-03-12.

[PATCH -next] perf/arm_dmc620_pmu: Fix error return code in dmc620_pmu_device_probe()

From: 'Wei Yongjun <hidden>
Date: 2021-03-12 07:57:04
Also in: kernel-janitors, lkml
Subsystem: arm pmu profiling and debugging, the rest · Maintainers: Will Deacon, Mark Rutland, Linus Torvalds

From: Wei Yongjun <redacted>

Fix to return negative error code -ENOMEM from the error handling
case instead of 0, as done elsewhere in this function.

Fixes: 53c218da220c ("driver/perf: Add PMU driver for the ARM DMC-620 memory controller")
Reported-by: Hulk Robot <redacted>
Signed-off-by: Wei Yongjun <redacted>
---
 drivers/perf/arm_dmc620_pmu.c | 1 +
 1 file changed, 1 insertion(+)
diff --git a/drivers/perf/arm_dmc620_pmu.c b/drivers/perf/arm_dmc620_pmu.c
index 66ad5b3ece19..f2a85500258d 100644
--- a/drivers/perf/arm_dmc620_pmu.c
+++ b/drivers/perf/arm_dmc620_pmu.c
@@ -681,6 +681,7 @@ static int dmc620_pmu_device_probe(struct platform_device *pdev)
 	if (!name) {
 		dev_err(&pdev->dev,
 			  "Create name failed, PMU @%pa\n", &res->start);
+		ret = -ENOMEM;
 		goto out_teardown_dev;
 	}
 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help