Re: [PATCH net 2/2] rxrpc: Fix the data_ready handler
From: Eric Dumazet
Date: Fri Oct 05 2018 - 12:07:44 EST
On 10/05/2018 07:18 AM, David Howells wrote:
> Eric Dumazet <eric.dumazet@xxxxxxxxx> wrote:
>
>> This looks a potential infinite loop to me ?
>
> I assume that you're talking about the case where the packets are coming in so
> fast that rxrpc is processing them as fast as they're coming in - or failing
> to keep up. I'm not sure what's the best thing to do in that case.
Well, this is exactly why we do not write such loops :/
sk_data_ready is not meant to process packets, it is meant to signal
to another entity (preferably running in process context and thus with proper
schedule points, and not blocking BH) that there is data ready to be consumed.
Under DOS, it is possible multiple cpus will sk_data_ready in parallel.