Subject: RE: [PATCH net-next v27 07/13] rtase: Implement a function to receive packets

From: Larry Chiu <[email-masked]>
Date: Wed, 21 Aug 2024 09:02:41 +0000

> > > And you should have a periodic service task / work which checks for
> > > buffers being exhausted, and if they are schedule NAPI so that it tries
> > > to allocate.
> >
> > We will redefine the rtase_rx_ring_fill() to check the buffers and
> > try to get page from the pool.
> > Should we return the budget to schedule this NAPI if there are some
> > empty buffers?
> 
> I wouldn't recommend that. If system is under memory stress
> we shouldn't be adding extra load by rescheduling NAPI.

Okay, I get it, but there's a problem.
If all buffers are empty, it indicates that the memory allocation failed
multiple times. Should we keep trying to allocate or just log an error 
message and stop it?