[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAGfqbt5qtcxjfEjxumffBBDRKPvJz-W=J9eTXiNkJ-PgBUH8RA@mail.gmail.com>
Date: Mon, 5 Sep 2022 22:46:01 +0200
From: Janusz Krzysztofik <jmkrzyszt@...il.com>
To: Aaro Koskinen <aaro.koskinen@....fi>,
Tony Lindgren <tony@...mide.com>, cgel.zte@...il.com
Cc: Russell King <linux@...linux.org.uk>,
linux-arm Mailing List <linux-arm-kernel@...ts.infradead.org>,
Linux OMAP Mailing List <linux-omap@...r.kernel.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Jinpeng Cui <cui.jinpeng2@....com.cn>,
Zeal Robot <zealci@....com.cn>
Subject: Re: [PATCH linux-next] ARM: omap1: remove redundant variables err
On Tuesday, 30 August 2022 16:21:36 CEST cgel.zte@...il.com wrote:
> From: Jinpeng Cui <cui.jinpeng2@....com.cn>
>
> Rturn value directly from platform_device_register()
> instead of getting value from redundant variable err.
>
> Reported-by: Zeal Robot <zealci@....com.cn>
> Signed-off-by: Jinpeng Cui <cui.jinpeng2@....com.cn>
Acked-by: Janusz Krzysztofik <jmkrzyszt@...il.com>
Note: The same change, form a different author @zte.com.cn, with a different
wording in commit message and description, was submitted a few hours before
this one. However, I decided to respond with my Ack to this one because
the other one was not sent to linux-omap@...r.kernel.org, then it didn't
reach OMAP patchwork. If my decision is not in line with some
recommendations and I should rather prefer the submission sent earlier then
please let me know and I'll respond with my Ack to it as well.
Thanks,
Janusz
> ---
> arch/arm/mach-omap1/board-ams-delta.c | 6 +-----
> 1 file changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/arch/arm/mach-omap1/board-ams-delta.c b/arch/arm/mach-omap1/board-ams-delta.c
> index 651c28d81132..e5531ef0fbde 100644
> --- a/arch/arm/mach-omap1/board-ams-delta.c
> +++ b/arch/arm/mach-omap1/board-ams-delta.c
> @@ -822,8 +822,6 @@ static int __init modem_nreset_init(void)
> */
> static int __init ams_delta_modem_init(void)
> {
> - int err;
> -
> if (!machine_is_ams_delta())
> return -ENODEV;
>
> @@ -832,9 +830,7 @@ static int __init ams_delta_modem_init(void)
> /* Initialize the modem_nreset regulator consumer before use */
> modem_priv.regulator = ERR_PTR(-ENODEV);
>
> - err = platform_device_register(&ams_delta_modem_device);
> -
> - return err;
> + return platform_device_register(&ams_delta_modem_device);
> }
> arch_initcall_sync(ams_delta_modem_init);
>
>
Powered by blists - more mailing lists