From: Stefan Schmidt <stefan@datenfreihafen.org>
To: Wei Yongjun <weiyongjun1@huawei.com>,
Alexander Aring <alex.aring@gmail.com>,
"David S. Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>
Cc: linux-wpan@vger.kernel.org, netdev@vger.kernel.org,
kernel-janitors@vger.kernel.org, Hulk Robot <hulkci@huawei.com>
Subject: Re: [PATCH net-next] ieee802154: fix error return code in ieee802154_llsec_getparams()
Date: Thu, 3 Jun 2021 11:01:51 +0200 [thread overview]
Message-ID: <b8700eed-1791-fd55-4568-dc4efeda35eb@datenfreihafen.org> (raw)
In-Reply-To: <20210519141614.3040055-1-weiyongjun1@huawei.com>
Hello.
On 19.05.21 16:16, Wei Yongjun wrote:
> Fix to return negative error code -ENOBUFS from the error handling
> case instead of 0, as done elsewhere in this function.
>
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---
> net/ieee802154/nl-mac.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/net/ieee802154/nl-mac.c b/net/ieee802154/nl-mac.c
> index 0c1b0770c59e..c23c152860b7 100644
> --- a/net/ieee802154/nl-mac.c
> +++ b/net/ieee802154/nl-mac.c
> @@ -680,8 +680,10 @@ int ieee802154_llsec_getparams(struct sk_buff *skb, struct genl_info *info)
> nla_put_u8(msg, IEEE802154_ATTR_LLSEC_SECLEVEL, params.out_level) ||
> nla_put_u32(msg, IEEE802154_ATTR_LLSEC_FRAME_COUNTER,
> be32_to_cpu(params.frame_counter)) ||
> - ieee802154_llsec_fill_key_id(msg, ¶ms.out_key))
> + ieee802154_llsec_fill_key_id(msg, ¶ms.out_key)) {
> + rc = -ENOBUFS;
> goto out_free;
> + }
>
> dev_put(dev);
This patch has been applied to the wpan tree and will be
part of the next pull request to net. Thanks!
regards
Stefan Schmidt
prev parent reply other threads:[~2021-06-03 9:08 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-19 14:16 [PATCH net-next] ieee802154: fix error return code in ieee802154_llsec_getparams() Wei Yongjun
2021-05-20 5:44 ` Dan Carpenter
2021-06-03 9:01 ` Stefan Schmidt [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=b8700eed-1791-fd55-4568-dc4efeda35eb@datenfreihafen.org \
--to=stefan@datenfreihafen.org \
--cc=alex.aring@gmail.com \
--cc=davem@davemloft.net \
--cc=hulkci@huawei.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=kuba@kernel.org \
--cc=linux-wpan@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=weiyongjun1@huawei.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