[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20120417054356.GB31278@redhat.com>
Date: Tue, 17 Apr 2012 08:43:58 +0300
From: "Michael S. Tsirkin" <mst@...hat.com>
To: Eric Dumazet <eric.dumazet@...il.com>
Cc: Jason Wang <jasowang@...hat.com>, netdev@...r.kernel.org,
xma@...ibm.com, davem@...emloft.net, linux-kernel@...r.kernel.org,
ebiederm@...ssion.com
Subject: Re: [PATCH 3/6] macvtap: zerocopy: validate vector length before
pinning user pages
On Tue, Apr 17, 2012 at 07:33:28AM +0200, Eric Dumazet wrote:
> On Mon, 2012-04-16 at 16:21 +0800, Jason Wang wrote:
> > Hi:
> > On 04/16/2012 02:53 PM, Eric Dumazet wrote:
> > if ((num_pages != size) ||
> > >> (num_pages> MAX_SKB_FRAGS - skb_shinfo(skb)->nr_frags))
> > >>
> > > Hi Jason
> > >
> > > Why is -EFAULT the right error code ?
> >
> > E2BIG or is there any error code you prefer?
>
> Might be good yes.
>
> However it sounds strange user cant write any size he wants (and kernel
> needs to build several skbs to fulfill user request)
We never supported arbitrary length writes:
macvtap is exactly like packet sockets in this regard.
--
MST
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists