From: YueHaibing <yuehaibing@huawei.com>
To: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>,
<davem@davemloft.net>, <roopa@cumulusnetworks.com>
Cc: <linux-kernel@vger.kernel.org>, <netdev@vger.kernel.org>,
<bridge@lists.linux-foundation.org>
Subject: Re: [PATCH net-next] net: bridge: remove unneeded variable 'err'
Date: Mon, 17 Dec 2018 19:16:56 +0800 [thread overview]
Message-ID: <d0c9ac6a-5c23-84dc-f45f-28bc2a3d20fe@huawei.com> (raw)
In-Reply-To: <e9b1e56e-4c37-aff4-b855-2523eae1ef49@cumulusnetworks.com>
On 2018/12/17 17:51, Nikolay Aleksandrov wrote:
> On 17/12/2018 11:46, YueHaibing wrote:
>> function br_multicast_toggle now always return 0,
>> so the variable 'err' is unneeded.
>> Also cleanup dead branch in br_changelink.
>>
>> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
>> ---
>> net/bridge/br_multicast.c | 3 +--
>> net/bridge/br_netlink.c | 4 +---
>> 2 files changed, 2 insertions(+), 5 deletions(-)
>>
>
> That is correct, but in such case just make it void.
In net/bridge/br_sysfs_br.c:
static ssize_t multicast_snooping_store(struct device *d,
struct device_attribute *attr,
const char *buf, size_t len)
{
return store_bridge_parm(d, buf, len, br_multicast_toggle);
}
and store_bridge_parm need the returned err.
>
>
>
>
next prev parent reply other threads:[~2018-12-17 11:17 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-17 9:46 YueHaibing
2018-12-17 9:51 ` Nikolay Aleksandrov
2018-12-17 11:16 ` YueHaibing [this message]
2018-12-17 11:21 ` Nikolay Aleksandrov
2018-12-18 23:50 ` David Miller
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=d0c9ac6a-5c23-84dc-f45f-28bc2a3d20fe@huawei.com \
--to=yuehaibing@huawei.com \
--cc=bridge@lists.linux-foundation.org \
--cc=davem@davemloft.net \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=nikolay@cumulusnetworks.com \
--cc=roopa@cumulusnetworks.com \
/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®