Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1516418
| From | Peter Griffin <peter.griffin@linaro.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH v11 13/14] dmaengine: st_fdma: Fix the error return code in st_fdma_probe() |
| Date | 2016-11-07 19:20 +0100 |
| Message-ID | <sAWGu-6RG-27@gated-at.bofh.it> (permalink) |
| References | <sAWGu-6RG-15@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
From: Wei Yongjun <weiyongjun1@huawei.com>
In case of error, the function st_slim_rproc_alloc() returns ERR_PTR()
and never returns NULL. The NULL test in the return value check should
be replaced with IS_ERR().
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Acked-by: Peter Griffin <peter.griffin@linaro.org>
---
drivers/dma/st_fdma.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/dma/st_fdma.c b/drivers/dma/st_fdma.c
index 232d354..bfb79bd 100644
--- a/drivers/dma/st_fdma.c
+++ b/drivers/dma/st_fdma.c
@@ -792,7 +792,7 @@ static int st_fdma_probe(struct platform_device *pdev)
}
fdev->slim_rproc = st_slim_rproc_alloc(pdev, fdev->fw_name);
- if (!fdev->slim_rproc) {
+ if (IS_ERR(fdev->slim_rproc)) {
ret = PTR_ERR(fdev->slim_rproc);
dev_err(&pdev->dev, "slim_rproc_alloc failed (%d)\n", ret);
goto err;
--
2.7.4
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH v11 00/14] Add support for FDMA DMA controller and slim core rproc found on STi chipsets Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:20 +0100 [PATCH v11 04/14] dmaengine: st_fdma: Add STMicroelectronics FDMA DT binding documentation Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:20 +0100 [PATCH v11 13/14] dmaengine: st_fdma: Fix the error return code in st_fdma_probe() Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:20 +0100 [PATCH v11 05/14] dmaengine: st_fdma: Add STMicroelectronics FDMA driver header file Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:20 +0100 [PATCH v11 10/14] ARM: multi_v7_defconfig: Enable STi FDMA driver Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:20 +0100 [PATCH v11 09/14] ARM: multi_v7_defconfig: Enable st_remoteproc driver. Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:20 +0100 [PATCH v11 14/14] dmaengine: st_fdma: Update st_fdma to 'depends on REMOTEPROC'. Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:20 +0100 [PATCH v11 11/14] ARM: multi_v7_defconfig: Enable STi and simple-card drivers. Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:30 +0100 [PATCH v11 02/14] remoteproc: st_slim_rproc: add a slimcore rproc driver Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:30 +0100 [PATCH v11 08/14] ARM: multi_v7_defconfig: Enable remoteproc core Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:30 +0100 [PATCH v11 07/14] MAINTAINERS: Add FDMA driver files to STi section. Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:30 +0100 [PATCH v11 03/14] MAINTAINERS: Add st slim core rproc driver to STi section. Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:30 +0100 [PATCH v11 06/14] dmaengine: st_fdma: Add STMicroelectronics FDMA engine driver support Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:30 +0100 [PATCH v11 12/14] dmaengine: st_fdma: fix uninitialized variable access Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:30 +0100 [PATCH v11 01/14] remoteproc: Update Kconfig setup to 'depends on REMOTEPROC' Peter Griffin <peter.griffin@linaro.org> - 2016-11-07 19:30 +0100
csiph-web