diff options
author | Yang Yingliang <yangyingliang@huawei.com> | 2023-08-09 17:19:53 +0800 |
---|---|---|
committer | Helge Deller <deller@gmx.de> | 2023-08-10 17:32:09 +0200 |
commit | 56cf894effc2946f273f7bfc9a28f3741978156c (patch) | |
tree | 1efd3eeaa5a17f410825b9271705d65d55dd0bae /arch | |
parent | a0f4b7879f2e14986200747d1b545e5daac8c624 (diff) | |
download | linux-stable-56cf894effc2946f273f7bfc9a28f3741978156c.tar.gz linux-stable-56cf894effc2946f273f7bfc9a28f3741978156c.tar.bz2 linux-stable-56cf894effc2946f273f7bfc9a28f3741978156c.zip |
parisc: pdt: Use PTR_ERR_OR_ZERO() to simplify code
Return PTR_ERR_OR_ZERO() instead of return 0 or PTR_ERR() to
simplify code.
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Signed-off-by: Helge Deller <deller@gmx.de>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/parisc/kernel/pdt.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/arch/parisc/kernel/pdt.c b/arch/parisc/kernel/pdt.c index 0d24735bd918..0f9b3b5914cf 100644 --- a/arch/parisc/kernel/pdt.c +++ b/arch/parisc/kernel/pdt.c @@ -354,10 +354,8 @@ static int __init pdt_initcall(void) return -ENODEV; kpdtd_task = kthread_run(pdt_mainloop, NULL, "kpdtd"); - if (IS_ERR(kpdtd_task)) - return PTR_ERR(kpdtd_task); - return 0; + return PTR_ERR_OR_ZERO(kpdtd_task); } late_initcall(pdt_initcall); |