All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: wangyunjian <wangyunjian@huawei.com>, <mst@redhat.com>,
	<jasowang@redhat.com>, <willemdebruijn.kernel@gmail.com>
Cc: <netdev@vger.kernel.org>,
	<virtualization@lists.linux-foundation.org>,
	<jerry.lilijun@huawei.com>, <chenchanghu@huawei.com>,
	<xudingke@huawei.com>, <brian.huangbin@huawei.com>
Subject: Re: [PATCH net v2] tun: fix return value when the number of iovs exceeds MAX_SKB_FRAGS
Date: Mon, 28 Dec 2020 13:43:09 -0800	[thread overview]
Message-ID: <20201228134309.1126941c@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> (raw)
In-Reply-To: <1608864736-24332-1-git-send-email-wangyunjian@huawei.com>

On Fri, 25 Dec 2020 10:52:16 +0800 wangyunjian wrote:
> From: Yunjian Wang <wangyunjian@huawei.com>
> 
> Currently the tun_napi_alloc_frags() function returns -ENOMEM when the
> number of iovs exceeds MAX_SKB_FRAGS + 1. However this is inappropriate,
> we should use -EMSGSIZE instead of -ENOMEM.
> 
> The following distinctions are matters:
> 1. the caller need to drop the bad packet when -EMSGSIZE is returned,
>    which means meeting a persistent failure.
> 2. the caller can try again when -ENOMEM is returned, which means
>    meeting a transient failure.
> 
> Fixes: 90e33d459407 ("tun: enable napi_gro_frags() for TUN/TAP driver")
> Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
> Acked-by: Willem de Bruijn <willemb@google.com>

Applied, thanks everyone!

      parent reply	other threads:[~2020-12-28 23:16 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-25  2:52 [PATCH net v2] tun: fix return value when the number of iovs exceeds MAX_SKB_FRAGS wangyunjian
2020-12-25  6:18 ` Jason Wang
2020-12-25  6:18   ` Jason Wang
2020-12-27  9:40 ` Michael S. Tsirkin
2020-12-27  9:40   ` Michael S. Tsirkin
2020-12-28 21:43 ` Jakub Kicinski [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=20201228134309.1126941c@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com \
    --to=kuba@kernel.org \
    --cc=brian.huangbin@huawei.com \
    --cc=chenchanghu@huawei.com \
    --cc=jasowang@redhat.com \
    --cc=jerry.lilijun@huawei.com \
    --cc=mst@redhat.com \
    --cc=netdev@vger.kernel.org \
    --cc=virtualization@lists.linux-foundation.org \
    --cc=wangyunjian@huawei.com \
    --cc=willemdebruijn.kernel@gmail.com \
    --cc=xudingke@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.