From: miaoqinglang <miaoqinglang@huawei.com>
To: Johan Hovold <johan@kernel.org>
Cc: <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH -next] gnss: simplify the return expression of gnss_uevent
Date: Fri, 9 Oct 2020 09:10:17 +0800 [thread overview]
Message-ID: <ff65fc05-b992-ed76-909d-37935287307a@huawei.com> (raw)
In-Reply-To: <20201008144247.GJ26280@localhost>
在 2020/10/8 22:42, Johan Hovold 写道:
> On Mon, Sep 21, 2020 at 09:10:28PM +0800, Qinglang Miao wrote:
>> Simplify the return expression.
>>
>> Signed-off-by: Qinglang Miao <miaoqinglang@huawei.com>
>
> The current code was written with an explicit error path on purpose, and
> there's no need to change it.
>
> Same applies to your other gnss ubx patch.
>
Glad for knowing that and it sounds resonable to me.
Thanks.
>> ---
>> drivers/gnss/core.c | 7 +------
>> 1 file changed, 1 insertion(+), 6 deletions(-)
>>
>> diff --git a/drivers/gnss/core.c b/drivers/gnss/core.c
>> index e6f94501c..e6b9ac9da 100644
>> --- a/drivers/gnss/core.c
>> +++ b/drivers/gnss/core.c
>> @@ -368,13 +368,8 @@ ATTRIBUTE_GROUPS(gnss);
>> static int gnss_uevent(struct device *dev, struct kobj_uevent_env *env)
>> {
>> struct gnss_device *gdev = to_gnss_device(dev);
>> - int ret;
>>
>> - ret = add_uevent_var(env, "GNSS_TYPE=%s", gnss_type_name(gdev));
>> - if (ret)
>> - return ret;
>> -
>> - return 0;
>> + return add_uevent_var(env, "GNSS_TYPE=%s", gnss_type_name(gdev));
>> }
>>
>> static int __init gnss_module_init(void)
>
> Johan
> .
>
prev parent reply other threads:[~2020-10-09 1:10 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-21 13:10 Qinglang Miao
2020-10-08 14:42 ` Johan Hovold
2020-10-09 1:10 ` miaoqinglang [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ff65fc05-b992-ed76-909d-37935287307a@huawei.com \
--to=miaoqinglang@huawei.com \
--cc=johan@kernel.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®