2019-10-06 18:48:03

by Julio Faracco

[permalink] [raw]
Subject: [PATCH RFC net-next 0/2] drivers: net: virtio_net: Implement

From: Julio Faracco <[email protected]>

Driver virtio_net is not handling error events for TX provided by
dev_watchdog. This event is reached when transmission queue is having
problems to transmit packets. To enable it, driver should have
.ndo_tx_timeout implemented. This serie has two commits:

In the past, we implemented a function to recover driver state when this
kind of event happens, but the structure was to complex for virtio_net
that moment. Alternativelly, this skeleton should be enough for now.

For further details, see thread:
https://lkml.org/lkml/2015/6/23/691

Patch 1/2:
Add statistic field for TX timeout events.

Patch 2/2:
Implement a skeleton function to debug TX timeout events.

Julio Faracco (2):
drivers: net: virtio_net: Add tx_timeout stats field
drivers: net: virtio_net: Add tx_timeout function

drivers/net/virtio_net.c | 33 ++++++++++++++++++++++++++++++++-
1 file changed, 32 insertions(+), 1 deletion(-)

--
2.21.0


2019-10-07 07:46:32

by Michael S. Tsirkin

[permalink] [raw]
Subject: Re: [PATCH RFC net-next 0/2] drivers: net: virtio_net: Implement

On Sun, Oct 06, 2019 at 03:45:13PM -0300, [email protected] wrote:
> From: Julio Faracco <[email protected]>
>
> Driver virtio_net is not handling error events for TX provided by
> dev_watchdog. This event is reached when transmission queue is having
> problems to transmit packets. To enable it, driver should have
> .ndo_tx_timeout implemented. This serie has two commits:
>
> In the past, we implemented a function to recover driver state when this
> kind of event happens, but the structure was to complex for virtio_net
> that moment.

It's more that it was missing a bunch of locks.

> Alternativelly, this skeleton should be enough for now.
>
> For further details, see thread:
> https://lkml.org/lkml/2015/6/23/691
>
> Patch 1/2:
> Add statistic field for TX timeout events.
>
> Patch 2/2:
> Implement a skeleton function to debug TX timeout events.
>
> Julio Faracco (2):
> drivers: net: virtio_net: Add tx_timeout stats field
> drivers: net: virtio_net: Add tx_timeout function
>
> drivers/net/virtio_net.c | 33 ++++++++++++++++++++++++++++++++-
> 1 file changed, 32 insertions(+), 1 deletion(-)
>
> --
> 2.21.0

2019-10-07 14:00:49

by Julio Faracco

[permalink] [raw]
Subject: Re: [PATCH RFC net-next 0/2] drivers: net: virtio_net: Implement

Em seg, 7 de out de 2019 às 04:43, Michael S. Tsirkin <[email protected]> escreveu:
>
> On Sun, Oct 06, 2019 at 03:45:13PM -0300, [email protected] wrote:
> > From: Julio Faracco <[email protected]>
> >
> > Driver virtio_net is not handling error events for TX provided by
> > dev_watchdog. This event is reached when transmission queue is having
> > problems to transmit packets. To enable it, driver should have
> > .ndo_tx_timeout implemented. This serie has two commits:
> >
> > In the past, we implemented a function to recover driver state when this
> > kind of event happens, but the structure was to complex for virtio_net
> > that moment.
>
> It's more that it was missing a bunch of locks.

Actually, we submitted this patch as a RFC to understand the community
perspective about this missing feature:
Complexity versus performance versus solution.

>
> > Alternativelly, this skeleton should be enough for now.
> >
> > For further details, see thread:
> > https://lkml.org/lkml/2015/6/23/691
> >
> > Patch 1/2:
> > Add statistic field for TX timeout events.
> >
> > Patch 2/2:
> > Implement a skeleton function to debug TX timeout events.
> >
> > Julio Faracco (2):
> > drivers: net: virtio_net: Add tx_timeout stats field
> > drivers: net: virtio_net: Add tx_timeout function
> >
> > drivers/net/virtio_net.c | 33 ++++++++++++++++++++++++++++++++-
> > 1 file changed, 32 insertions(+), 1 deletion(-)
> >
> > --
> > 2.21.0