From: Helmut Buchsbaum <helmut.buchsbaum@gmail.com>
To: Wei Yongjun <weiyj.lk@gmail.com>,
Nicolas Ferre <nicolas.ferre@atmel.com>
Cc: netdev@vger.kernel.org
Subject: Re: [PATCH -next] net: macb: fix missing unlock on error in macb_start_xmit()
Date: Mon, 12 Sep 2016 19:40:27 +0200 [thread overview]
Message-ID: <1119c72d-2731-4bb4-bc52-316a5611c48b@gmail.com> (raw)
In-Reply-To: <1473506277-31304-1-git-send-email-weiyj.lk@gmail.com>
On 09/10/2016 01:17 PM, Wei Yongjun wrote:
> From: Wei Yongjun <weiyongjun1@huawei.com>
>
> Fix missing unlock before return from function macb_start_xmit()
> in the error handling case.
>
> Fixes: 007e4ba3ee13 ("net: macb: initialize checksum when using
> checksum offloading")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---
> drivers/net/ethernet/cadence/macb.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/cadence/macb.c b/drivers/net/ethernet/cadence/macb.c
> index 0294b6a..63144bb 100644
> --- a/drivers/net/ethernet/cadence/macb.c
> +++ b/drivers/net/ethernet/cadence/macb.c
> @@ -1398,7 +1398,7 @@ static int macb_start_xmit(struct sk_buff *skb, struct net_device *dev)
>
> if (macb_clear_csum(skb)) {
> dev_kfree_skb_any(skb);
> - return NETDEV_TX_OK;
> + goto unlock;
> }
>
> /* Map socket buffer for DMA transfer */
>
You are definitely right. Sorry I missed that obvious point and for
causing any inconveniences.
BTW, I see there are obviously quite a few users of MACB
implementations. I'm just curious if anybody else ever encountered the
checksum problem or if this a matter of Zynq implementation only.
Regards,
Helmut
next prev parent reply other threads:[~2016-09-12 17:40 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-10 11:17 [PATCH -next] net: macb: fix missing unlock on error in macb_start_xmit() Wei Yongjun
2016-09-12 7:38 ` Nicolas Ferre
2016-09-12 17:40 ` Helmut Buchsbaum [this message]
2016-09-29 17:21 ` Nicolas Ferre
2016-09-13 15:42 ` 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=1119c72d-2731-4bb4-bc52-316a5611c48b@gmail.com \
--to=helmut.buchsbaum@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=nicolas.ferre@atmel.com \
--cc=weiyj.lk@gmail.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