From: "Chen, Rong A" <rong.a.chen@intel.com>
To: Dan Carpenter <error27@gmail.com>,
Mat Martineau <mathew.j.martineau@linux.intel.com>,
lkp@intel.com
Cc: oe-kbuild@lists.linux.dev, Florian Westphal <fw@strlen.de>,
oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org,
mptcp@lists.linux.dev,
Matthieu Baerts <matthieu.baerts@tessares.net>
Subject: Re: net/mptcp/pm_netlink.c:1169 mptcp_pm_parse_pm_addr_attr() warn: missing error code? 'err'
Date: Tue, 6 Dec 2022 18:42:52 +0800 [thread overview]
Message-ID: <3b6b27ec-e478-1e71-a84e-e1177827d437@intel.com> (raw)
In-Reply-To: <Y4sI65oadrVtBlnR@kadam>
On 12/3/2022 4:29 PM, Dan Carpenter wrote:
> On Fri, Dec 02, 2022 at 03:38:01PM -0800, Mat Martineau wrote:
>>> 01cacb00b35cb6 Paolo Abeni 2020-03-27 1158 /* no validation needed - was already done via nested policy */
>>> 01cacb00b35cb6 Paolo Abeni 2020-03-27 1159 err = nla_parse_nested_deprecated(tb, MPTCP_PM_ADDR_ATTR_MAX, attr,
>>> 01cacb00b35cb6 Paolo Abeni 2020-03-27 1160 mptcp_pm_addr_policy, info->extack);
>>> 01cacb00b35cb6 Paolo Abeni 2020-03-27 1161 if (err)
>>> 01cacb00b35cb6 Paolo Abeni 2020-03-27 1162 return err;
>>> 01cacb00b35cb6 Paolo Abeni 2020-03-27 1163
>>> 982f17ba1a2534 Florian Westphal 2022-05-03 1164 if (tb[MPTCP_PM_ADDR_ATTR_ID])
>>> 982f17ba1a2534 Florian Westphal 2022-05-03 1165 addr->id = nla_get_u8(tb[MPTCP_PM_ADDR_ATTR_ID]);
>>> 982f17ba1a2534 Florian Westphal 2022-05-03 1166
>>> 01cacb00b35cb6 Paolo Abeni 2020-03-27 1167 if (!tb[MPTCP_PM_ADDR_ATTR_FAMILY]) {
>>> 01cacb00b35cb6 Paolo Abeni 2020-03-27 1168 if (!require_family)
>>> 982f17ba1a2534 Florian Westphal 2022-05-03 @1169 return err;
>>>
>>> "err" is zero at this point. Presumably a negative error code was
>>> intended.
>>
>> Hi Dan -
>>
>> The intended error code is 0 here: the return happens if no
>> MPTCP_PM_ADDR_ATTR_FAMILY value is present and require_family is false.
>>
>> It would be clearer to "return 0;", but the code is working as expected.
>>
>>
>> Could you be sure to cc mptcp@lists.linux.dev and
>> matthieu.baerts@tessares.net for future MPTCP issues?
Hi Mat,
Sorry for the delay, we'll cc you and the mailing list in the future.
Best Regards,
Rong Chen
>
> These emails are automatically generated by the kbuild team. I don't
> know what kind of heuristics they use... I've put them on the To
> header. There is probably a reason why they don't just use
> get_maintainer.pl...
>
> regards,
> dan carpenter
>
>
prev parent reply other threads:[~2022-12-06 10:42 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-02 6:39 net/mptcp/pm_netlink.c:1169 mptcp_pm_parse_pm_addr_attr() warn: missing error code? 'err' kernel test robot
2022-12-02 8:49 ` Dan Carpenter
2022-12-02 23:38 ` Mat Martineau
2022-12-03 8:29 ` Dan Carpenter
2022-12-06 10:42 ` Chen, Rong A [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=3b6b27ec-e478-1e71-a84e-e1177827d437@intel.com \
--to=rong.a.chen@intel.com \
--cc=error27@gmail.com \
--cc=fw@strlen.de \
--cc=linux-kernel@vger.kernel.org \
--cc=lkp@intel.com \
--cc=mathew.j.martineau@linux.intel.com \
--cc=matthieu.baerts@tessares.net \
--cc=mptcp@lists.linux.dev \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=oe-kbuild@lists.linux.dev \
/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;
as well as URLs for NNTP newsgroup(s).