Re: [PATCH net v4 2/2] vhost_net: fix tx queue stuck when sendmsg fails

2020-12-24 Thread Jason Wang
On 2020/12/24 下午5:09, wangyunjian wrote: -EAGAIN and -ENOBFS are fine. But I don't see how -ENOMEM can be returned. The tun_build_skb() and tun_napi_alloc_frags() return -ENOMEM when memory allocation fails. Thanks You're right. So I think we need check them all. In the future, we need th

RE: [PATCH net v4 2/2] vhost_net: fix tx queue stuck when sendmsg fails

2020-12-24 Thread wangyunjian
(Jerry) ; chenchanghu > ; xudingke ; huangbin (J) > > Subject: Re: [PATCH net v4 2/2] vhost_net: fix tx queue stuck when sendmsg > fails > > > On 2020/12/24 下午12:37, wangyunjian wrote: > >> -Original Message- > >> From: Jason Wang [mailto:jasow...

Re: [PATCH net v4 2/2] vhost_net: fix tx queue stuck when sendmsg fails

2020-12-23 Thread Jason Wang
; Lilijun (Jerry) ; chenchanghu ; xudingke ; huangbin (J) Subject: Re: [PATCH net v4 2/2] vhost_net: fix tx queue stuck when sendmsg fails On 2020/12/24 上午10:25, wangyunjian wrote: From: Yunjian Wang Currently the driver doesn't drop a packet which can't be sent by tun (e.g bad p

RE: [PATCH net v4 2/2] vhost_net: fix tx queue stuck when sendmsg fails

2020-12-23 Thread wangyunjian
y) > ; chenchanghu ; > xudingke ; huangbin (J) > > Subject: Re: [PATCH net v4 2/2] vhost_net: fix tx queue stuck when sendmsg > fails > > > On 2020/12/24 上午10:25, wangyunjian wrote: > > From: Yunjian Wang > > > > Currently the driver doesn't drop

Re: [PATCH net v4 2/2] vhost_net: fix tx queue stuck when sendmsg fails

2020-12-23 Thread Jason Wang
On 2020/12/24 上午10:25, wangyunjian wrote: From: Yunjian Wang Currently the driver doesn't drop a packet which can't be sent by tun (e.g bad packet). In this case, the driver will always process the same packet lead to the tx queue stuck. To fix this issue: 1. in the case of persistent failur

Re: [PATCH net v4 2/2] vhost_net: fix tx queue stuck when sendmsg fails

2020-12-23 Thread Willem de Bruijn
On Wed, Dec 23, 2020 at 9:25 PM wangyunjian wrote: > > From: Yunjian Wang > > Currently the driver doesn't drop a packet which can't be sent by tun > (e.g bad packet). In this case, the driver will always process the > same packet lead to the tx queue stuck. > > To fix this issue: > 1. in the cas

[PATCH net v4 2/2] vhost_net: fix tx queue stuck when sendmsg fails

2020-12-23 Thread wangyunjian
From: Yunjian Wang Currently the driver doesn't drop a packet which can't be sent by tun (e.g bad packet). In this case, the driver will always process the same packet lead to the tx queue stuck. To fix this issue: 1. in the case of persistent failure (e.g bad packet), the driver can skip this d