Re: [PATCH v2] kni: fix possible alloc_q starvation when mbufs are exhausted

2022-12-09 Thread Ferruh Yigit
On 11/11/2022 9:12 AM, Matt wrote: > > > On Thu, Nov 10, 2022 at 12:39 AM Stephen Hemminger > mailto:step...@networkplumber.org>> wrote: > > On Wed,  9 Nov 2022 14:04:34 +0800 > Yangchao Zhou mailto:zhouya...@gmail.com>> wrote: > > > In some scenarios, mbufs returned by rte_kni_rx_b

Re: [PATCH v2] kni: fix possible alloc_q starvation when mbufs are exhausted

2022-11-11 Thread Matt
On Thu, Nov 10, 2022 at 12:39 AM Stephen Hemminger < step...@networkplumber.org> wrote: > On Wed, 9 Nov 2022 14:04:34 +0800 > Yangchao Zhou wrote: > > > In some scenarios, mbufs returned by rte_kni_rx_burst are not freed > > immediately. So kni_allocate_mbufs may be failed, but we don't know. >

Re: [PATCH v2] kni: fix possible alloc_q starvation when mbufs are exhausted

2022-11-09 Thread Stephen Hemminger
On Wed, 9 Nov 2022 14:04:34 +0800 Yangchao Zhou wrote: > In some scenarios, mbufs returned by rte_kni_rx_burst are not freed > immediately. So kni_allocate_mbufs may be failed, but we don't know. > > Even worse, when alloc_q is completely exhausted, kni_net_tx in > rte_kni.ko will drop all tx p

[PATCH v2] kni: fix possible alloc_q starvation when mbufs are exhausted

2022-11-08 Thread Yangchao Zhou
In some scenarios, mbufs returned by rte_kni_rx_burst are not freed immediately. So kni_allocate_mbufs may be failed, but we don't know. Even worse, when alloc_q is completely exhausted, kni_net_tx in rte_kni.ko will drop all tx packets. kni_allocate_mbufs is never called again, even if the mbufs