[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <6bb15158-829e-f032-dc10-110e831da8c3@gmail.com>
Date: Mon, 3 Apr 2023 23:38:41 +0900
From: Chanwoo Choi <cwchoi00@...il.com>
To: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
Bumwoo Lee <bw365.lee@...sung.com>,
linux-kernel@...r.kernel.org
Cc: MyungJoo Ham <myungjoo.ham@...sung.com>,
Chanwoo Choi <cw00.choi@...sung.com>
Subject: Re: [PATCH v1 14/14] extcon: Use positive conditional in ternary
operator
On 23. 3. 22. 23:40, Andy Shevchenko wrote:
> It's easier to parse by a human being the positive conditional.
>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
> ---
> drivers/extcon/extcon.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/extcon/extcon.c b/drivers/extcon/extcon.c
> index edfa0450e605..3e8522d522b4 100644
> --- a/drivers/extcon/extcon.c
> +++ b/drivers/extcon/extcon.c
> @@ -1466,7 +1466,7 @@ EXPORT_SYMBOL_GPL(extcon_get_edev_by_phandle);
> */
> const char *extcon_get_edev_name(struct extcon_dev *edev)
> {
> - return !edev ? NULL : edev->name;
> + return edev ? edev->name : NULL;
> }
> EXPORT_SYMBOL_GPL(extcon_get_edev_name);
>
It is not fix-up patch and I'm not sure that it is beneficial patch.
I will not apply it.
--
Best Regards,
Samsung Electronics
Chanwoo Choi
Powered by blists - more mailing lists