* Re: [PATCH -next] firmware: arm_sdei: Fix return value check in sdei_present_dt()
2018-01-15 10:41 ` Wei Yongjun
(?)
@ 2018-01-15 10:38 ` James Morse
-1 siblings, 0 replies; 9+ messages in thread
From: James Morse @ 2018-01-15 10:38 UTC (permalink / raw)
To: Wei Yongjun, Catalin Marinas
Cc: linux-arm-kernel, linux-kernel, kernel-janitors
Hi Wei,
On 15/01/18 10:41, Wei Yongjun wrote:
> In case of error, the function of_platform_device_create() returns
> NULL pointer not ERR_PTR(). The IS_ERR() test in the return value
> check should be replaced with NULL test.
Bother, so it does!
Thanks for catching this.
Acked-by: James Morse <james.morse@arm.com>
Thanks,
James
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH -next] firmware: arm_sdei: Fix return value check in sdei_present_dt()
@ 2018-01-15 10:38 ` James Morse
0 siblings, 0 replies; 9+ messages in thread
From: James Morse @ 2018-01-15 10:38 UTC (permalink / raw)
To: linux-arm-kernel
Hi Wei,
On 15/01/18 10:41, Wei Yongjun wrote:
> In case of error, the function of_platform_device_create() returns
> NULL pointer not ERR_PTR(). The IS_ERR() test in the return value
> check should be replaced with NULL test.
Bother, so it does!
Thanks for catching this.
Acked-by: James Morse <james.morse@arm.com>
Thanks,
James
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH -next] firmware: arm_sdei: Fix return value check in sdei_present_dt()
@ 2018-01-15 10:38 ` James Morse
0 siblings, 0 replies; 9+ messages in thread
From: James Morse @ 2018-01-15 10:38 UTC (permalink / raw)
To: linux-arm-kernel
Hi Wei,
On 15/01/18 10:41, Wei Yongjun wrote:
> In case of error, the function of_platform_device_create() returns
> NULL pointer not ERR_PTR(). The IS_ERR() test in the return value
> check should be replaced with NULL test.
Bother, so it does!
Thanks for catching this.
Acked-by: James Morse <james.morse@arm.com>
Thanks,
James
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH -next] firmware: arm_sdei: Fix return value check in sdei_present_dt()
2018-01-15 10:38 ` James Morse
(?)
@ 2018-01-15 10:41 ` Wei Yongjun
-1 siblings, 0 replies; 9+ messages in thread
From: Wei Yongjun @ 2018-01-15 10:41 UTC (permalink / raw)
To: James Morse, Catalin Marinas
Cc: Wei Yongjun, linux-arm-kernel, linux-kernel, kernel-janitors
In case of error, the function of_platform_device_create() returns
NULL pointer not ERR_PTR(). The IS_ERR() test in the return value
check should be replaced with NULL test.
Fixes: 677a60bd2003 ("firmware: arm_sdei: Discover SDEI support via ACPI")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
drivers/firmware/arm_sdei.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/firmware/arm_sdei.c b/drivers/firmware/arm_sdei.c
index 8f6563c..1ea7164 100644
--- a/drivers/firmware/arm_sdei.c
+++ b/drivers/firmware/arm_sdei.c
@@ -1023,7 +1023,7 @@ static bool __init sdei_present_dt(void)
pdev = of_platform_device_create(np, sdei_driver.driver.name, NULL);
of_node_put(np);
- if (IS_ERR(pdev))
+ if (!pdev)
return false;
return true;
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH -next] firmware: arm_sdei: Fix return value check in sdei_present_dt()
@ 2018-01-15 10:41 ` Wei Yongjun
0 siblings, 0 replies; 9+ messages in thread
From: Wei Yongjun @ 2018-01-15 10:41 UTC (permalink / raw)
To: linux-arm-kernel
In case of error, the function of_platform_device_create() returns
NULL pointer not ERR_PTR(). The IS_ERR() test in the return value
check should be replaced with NULL test.
Fixes: 677a60bd2003 ("firmware: arm_sdei: Discover SDEI support via ACPI")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
drivers/firmware/arm_sdei.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/firmware/arm_sdei.c b/drivers/firmware/arm_sdei.c
index 8f6563c..1ea7164 100644
--- a/drivers/firmware/arm_sdei.c
+++ b/drivers/firmware/arm_sdei.c
@@ -1023,7 +1023,7 @@ static bool __init sdei_present_dt(void)
pdev = of_platform_device_create(np, sdei_driver.driver.name, NULL);
of_node_put(np);
- if (IS_ERR(pdev))
+ if (!pdev)
return false;
return true;
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH -next] firmware: arm_sdei: Fix return value check in sdei_present_dt()
@ 2018-01-15 10:41 ` Wei Yongjun
0 siblings, 0 replies; 9+ messages in thread
From: Wei Yongjun @ 2018-01-15 10:41 UTC (permalink / raw)
To: linux-arm-kernel
In case of error, the function of_platform_device_create() returns
NULL pointer not ERR_PTR(). The IS_ERR() test in the return value
check should be replaced with NULL test.
Fixes: 677a60bd2003 ("firmware: arm_sdei: Discover SDEI support via ACPI")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
drivers/firmware/arm_sdei.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/firmware/arm_sdei.c b/drivers/firmware/arm_sdei.c
index 8f6563c..1ea7164 100644
--- a/drivers/firmware/arm_sdei.c
+++ b/drivers/firmware/arm_sdei.c
@@ -1023,7 +1023,7 @@ static bool __init sdei_present_dt(void)
pdev = of_platform_device_create(np, sdei_driver.driver.name, NULL);
of_node_put(np);
- if (IS_ERR(pdev))
+ if (!pdev)
return false;
return true;
^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH -next] firmware: arm_sdei: Fix return value check in sdei_present_dt()
2018-01-15 10:41 ` Wei Yongjun
(?)
@ 2018-01-15 18:17 ` Catalin Marinas
-1 siblings, 0 replies; 9+ messages in thread
From: Catalin Marinas @ 2018-01-15 18:17 UTC (permalink / raw)
To: Wei Yongjun; +Cc: James Morse, kernel-janitors, linux-kernel, linux-arm-kernel
On Mon, Jan 15, 2018 at 10:41:53AM +0000, Wei Yongjun wrote:
> In case of error, the function of_platform_device_create() returns
> NULL pointer not ERR_PTR(). The IS_ERR() test in the return value
> check should be replaced with NULL test.
>
> Fixes: 677a60bd2003 ("firmware: arm_sdei: Discover SDEI support via ACPI")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Applied. Thanks.
--
Catalin
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH -next] firmware: arm_sdei: Fix return value check in sdei_present_dt()
@ 2018-01-15 18:17 ` Catalin Marinas
0 siblings, 0 replies; 9+ messages in thread
From: Catalin Marinas @ 2018-01-15 18:17 UTC (permalink / raw)
To: linux-arm-kernel
On Mon, Jan 15, 2018 at 10:41:53AM +0000, Wei Yongjun wrote:
> In case of error, the function of_platform_device_create() returns
> NULL pointer not ERR_PTR(). The IS_ERR() test in the return value
> check should be replaced with NULL test.
>
> Fixes: 677a60bd2003 ("firmware: arm_sdei: Discover SDEI support via ACPI")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Applied. Thanks.
--
Catalin
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH -next] firmware: arm_sdei: Fix return value check in sdei_present_dt()
@ 2018-01-15 18:17 ` Catalin Marinas
0 siblings, 0 replies; 9+ messages in thread
From: Catalin Marinas @ 2018-01-15 18:17 UTC (permalink / raw)
To: linux-arm-kernel
On Mon, Jan 15, 2018 at 10:41:53AM +0000, Wei Yongjun wrote:
> In case of error, the function of_platform_device_create() returns
> NULL pointer not ERR_PTR(). The IS_ERR() test in the return value
> check should be replaced with NULL test.
>
> Fixes: 677a60bd2003 ("firmware: arm_sdei: Discover SDEI support via ACPI")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Applied. Thanks.
--
Catalin
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2018-01-15 18:17 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-15 10:41 [PATCH -next] firmware: arm_sdei: Fix return value check in sdei_present_dt() Wei Yongjun
2018-01-15 10:41 ` Wei Yongjun
2018-01-15 10:41 ` Wei Yongjun
2018-01-15 10:38 ` James Morse
2018-01-15 10:38 ` James Morse
2018-01-15 10:38 ` James Morse
2018-01-15 18:17 ` Catalin Marinas
2018-01-15 18:17 ` Catalin Marinas
2018-01-15 18:17 ` Catalin Marinas
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.