On 2017年03月30日 04:14, Michael S. Tsirkin wrote:
We already do a reset once in remove_vq_common -
there appears to be no point in doing another one
when we add/remove XDP.
Signed-off-by: Michael S. Tsirkin
---
drivers/net/virtio_net.c | 1 -
1 file changed, 1 deletion(-)
On 2017年03月30日 01:42, Michael S. Tsirkin wrote:
When ring size is small (<32 entries) making buffers smaller means a
full ring might not be able to hold enough buffers to fit a single large
packet.
Make sure a ring full of buffers is large enough to allow at least one
packet of max size.
On 2017年03月29日 20:38, Michael S. Tsirkin wrote:
If one enables e.g. jumbo frames without mergeable
buffers, packets won't fit in 1500 byte buffers
we use. Switch to big packet mode instead.
TODO: make sizing more exact, possibly extend small
packet mode to use larger pages.
Signed-off-by:
On 2017年03月29日 20:37, Michael S. Tsirkin wrote:
On xdp error we try to free head_skb without having
initialized it, that's clearly bogus.
Fixes: f600b6905015 ("virtio_net: Add XDP support")
Cc: John Fastabend
Signed-off-by: Michael S. Tsirkin
---
tree: https://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost.git linux-next
head: d01047cb281d27bcedbf705089bdd38d86d20b01
commit: a965e977a1038cd738f874b5ee8a16d4fa55c64d [6/19] virtio: add context
flag to find vqs
config: x86_64-randconfig-x015-201713 (attached as .config)
compiler:
On 2017年03月30日 10:33, Michael S. Tsirkin wrote:
On Thu, Mar 30, 2017 at 10:16:15AM +0800, Jason Wang wrote:
On 2017年03月29日 20:07, Michael S. Tsirkin wrote:
On Tue, Mar 21, 2017 at 12:04:47PM +0800, Jason Wang wrote:
For the socket that exports its skb array, we can use lockless polling
to
On Thu, Mar 30, 2017 at 10:16:15AM +0800, Jason Wang wrote:
>
>
> On 2017年03月29日 20:07, Michael S. Tsirkin wrote:
> > On Tue, Mar 21, 2017 at 12:04:47PM +0800, Jason Wang wrote:
> > > For the socket that exports its skb array, we can use lockless polling
> > > to avoid touching spinlock during
On 2017年03月29日 20:07, Michael S. Tsirkin wrote:
On Tue, Mar 21, 2017 at 12:04:47PM +0800, Jason Wang wrote:
For the socket that exports its skb array, we can use lockless polling
to avoid touching spinlock during busy polling.
Signed-off-by: Jason Wang
---
tree: https://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost.git linux-next
head: 8ab881d0e8136390da79aa0902fe03d2f6c65e32
commit: 281310d52c1d63630f54b1ac5cca6e9eb8715b3a [6/19] virtio: add context
flag to find vqs
reproduce:
# apt-get install sparse
git checkout
> -Original Message-
> From: Michael S. Tsirkin [mailto:m...@redhat.com]
> Sent: Thursday, March 30, 2017 4:49 AM
> Subject: [PATCH 1/6] virtio: wrap find_vqs
>
> We are going to add more parameters to find_vqs, let's wrap the call so
> we don't need to tweak all drivers every time.
>
>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost.git linux-next
head: 8ab881d0e8136390da79aa0902fe03d2f6c65e32
commit: 281310d52c1d63630f54b1ac5cca6e9eb8715b3a [6/19] virtio: add context
flag to find vqs
config: x86_64-randconfig-i0-201713 (attached as .config)
compiler:
tree: https://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost.git linux-next
head: 8ab881d0e8136390da79aa0902fe03d2f6c65e32
commit: 281310d52c1d63630f54b1ac5cca6e9eb8715b3a [6/19] virtio: add context
flag to find vqs
config: i386-randconfig-s0-201713 (attached as .config)
compiler: gcc-6
On Wed, Mar 29, 2017 at 06:53:27PM +0800, Jason Wang wrote:
>
>
> On 2017年03月29日 18:46, Pankaj Gupta wrote:
> > Hi Jason,
> >
> > > On 2017年03月23日 13:34, Jason Wang wrote:
> > > >
> > > > > > +{
> > > > > > +if (rvq->rh != rvq->rt)
> > > > > > +goto out;
> > > > > > +
> > > > > > +
We don't need to align length to any particular
value anymore. Aligning to L1 cache size probably
sill makes sense to reduce false sharing.
Signed-off-by: Michael S. Tsirkin
---
drivers/net/virtio_net.c | 13 +
1 file changed, 1 insertion(+), 12 deletions(-)
diff
With mergeable buffers we never use s/g for rx,
so allow specifying context in that case.
Signed-off-by: Michael S. Tsirkin
---
drivers/net/virtio_net.c | 15 ++-
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/drivers/net/virtio_net.c
Use the new _ctx virtio API to maintain true length for each buffer.
Signed-off-by: Michael S. Tsirkin
---
drivers/net/virtio_net.c | 91 +++-
1 file changed, 44 insertions(+), 47 deletions(-)
diff --git a/drivers/net/virtio_net.c
Allow extra context per descriptor. To avoid slow down for data path,
this disables use of indirect descriptors for this vq.
Signed-off-by: Michael S. Tsirkin
---
drivers/virtio/virtio_ring.c | 70
include/linux/virtio.h | 9
Allows maintaining extra context per vq. For ease of use, passing in
NULL is legal and disables the feature for all vqs.
Signed-off-by: Michael S. Tsirkin
---
drivers/misc/mic/vop/vop_main.c| 9 ++---
drivers/s390/virtio/kvm_virtio.c | 6 --
We are going to add more parameters to find_vqs, let's wrap the call so
we don't need to tweak all drivers every time.
Signed-off-by: Michael S. Tsirkin
---
drivers/block/virtio_blk.c | 3 +--
drivers/char/virtio_console.c | 6 +++---
We try to disable callbacks on c_ivq even without multiport
even though that vq is not initialized in this configuration.
Fixes: c743d09dbd01 ("virtio: console: Disable callbacks for virtqueues at
start of S4 freeze")
Suggested-by: Mike Galbraith
Signed-off-by: Michael S. Tsirkin
We already do a reset once in remove_vq_common -
there appears to be no point in doing another one
when we add/remove XDP.
Signed-off-by: Michael S. Tsirkin
---
drivers/net/virtio_net.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/net/virtio_net.c
On Fri, Mar 17, 2017 at 02:55:33PM +0800, Wei Wang wrote:
> On 03/17/2017 05:28 AM, Andrew Morton wrote:
> > On Thu, 16 Mar 2017 15:08:46 +0800 Wei Wang wrote:
> >
> > > From: Liang Li
> > >
> > > This patch adds a function to provides a snapshot of
When ring size is small (<32 entries) making buffers smaller means a
full ring might not be able to hold enough buffers to fit a single large
packet.
Make sure a ring full of buffers is large enough to allow at least one
packet of max size.
Fixes: 2613af0ed18a ("virtio_net: migrate mergeable rx
On Wed, Mar 29, 2017 at 08:15:04PM +0300, Michael S. Tsirkin wrote:
> When ring size is small (<32 entries) making buffers smaller means a
> full ring might not be able to hold enough buffers to fit a single large
> packet.
>
> Make sure a ring full of buffers is large enough to allow at least
When ring size is small (<32 entries) making buffers smaller means a
full ring might not be able to hold enough buffers to fit a single large
packet.
Make sure a ring full of buffers is large enough to allow at least one
packet of max size.
Fixes: 2613af0ed18a ("virtio_net: migrate mergeable rx
virtio attempts to clear the MTU feature bit if the value is out of the
supported range, but this has no real effect since FEATURES_OK has
already been set.
Fix this up by checking the MTU in the new validate callback.
Fixes: 14de9d114a82 ("virtio-net: Add initial MTU advice feature")
Some drivers can't support all features in all configurations. At the
moment we blindly set FEATURES_OK and later FAILED. Support this better
by adding a callback drivers can use to do some early checks.
Signed-off-by: Michael S. Tsirkin
---
drivers/virtio/virtio.c | 6 ++
On Wed, Mar 29, 2017 at 03:38:09PM +0300, Michael S. Tsirkin wrote:
> If one enables e.g. jumbo frames without mergeable
> buffers, packets won't fit in 1500 byte buffers
> we use. Switch to big packet mode instead.
> TODO: make sizing more exact, possibly extend small
> packet mode to use larger
On Wed, Mar 08, 2017 at 03:56:24PM +0800, Yuanhan Liu wrote:
> On Wed, Mar 08, 2017 at 03:09:48PM +0800, Yuanhan Liu wrote:
> > On Wed, Mar 01, 2017 at 03:07:29AM +0200, Michael S. Tsirkin wrote:
> > > On Tue, Feb 28, 2017 at 12:29:43PM +0800, Yuanhan Liu wrote:
> > > > Hi Michael,
> > > >
> > >
If one enables e.g. jumbo frames without mergeable
buffers, packets won't fit in 1500 byte buffers
we use. Switch to big packet mode instead.
TODO: make sizing more exact, possibly extend small
packet mode to use larger pages.
Signed-off-by: Michael S. Tsirkin
---
On xdp error we try to free head_skb without having
initialized it, that's clearly bogus.
Fixes: f600b6905015 ("virtio_net: Add XDP support")
Cc: John Fastabend
Signed-off-by: Michael S. Tsirkin
---
drivers/net/virtio_net.c | 2 +-
1 file changed, 1
On Tue, Mar 21, 2017 at 12:04:47PM +0800, Jason Wang wrote:
> For the socket that exports its skb array, we can use lockless polling
> to avoid touching spinlock during busy polling.
>
> Signed-off-by: Jason Wang
> ---
> drivers/vhost/net.c | 7 +--
> 1 file changed, 5
On 2017年03月29日 18:46, Pankaj Gupta wrote:
Hi Jason,
On 2017年03月23日 13:34, Jason Wang wrote:
+{
+if (rvq->rh != rvq->rt)
+goto out;
+
+rvq->rh = rvq->rt = 0;
+rvq->rt = skb_array_consume_batched_bh(rvq->rx_array, rvq->rxq,
+VHOST_RX_BATCH);
A
Hi Jason,
>
> On 2017年03月23日 13:34, Jason Wang wrote:
> >
> >
> >>
> >>> +{
> >>> +if (rvq->rh != rvq->rt)
> >>> +goto out;
> >>> +
> >>> +rvq->rh = rvq->rt = 0;
> >>> +rvq->rt = skb_array_consume_batched_bh(rvq->rx_array, rvq->rxq,
> >>> +
On 2017年03月23日 13:34, Jason Wang wrote:
+{
+if (rvq->rh != rvq->rt)
+goto out;
+
+rvq->rh = rvq->rt = 0;
+rvq->rt = skb_array_consume_batched_bh(rvq->rx_array, rvq->rxq,
+VHOST_RX_BATCH);
A comment explaining why is is -bh would be helpful.
35 matches
Mail list logo