Subject: Re: Handling receive packets with limited buffer space

From: Andi Kleen <[email-masked]>
Date: Sat, 20 Mar 2010 16:01:40 +0100

Amit Uttamchandani <[email-masked]> writes:

> In my modified ethoc.c driver, I am using only one receive buffer
> descriptor due to limited space. This works fairly well for small
> packets (arp, pings, etc.).
>
> However, doing a 'wget' and downloading a file causes lots of drops and
> thus results in a terminated connection.
>
> How do I go about dealing with this? I tried stopping the queue
> (netif_stop_queue) while I'm processing the rx skb and then resuming it
> once I'm done, but this did not seem to help.
>
> Any ideas on this?

You'll need to allocate a new skb and copy into it before
passing the data up the stack.

-Andi
-- 
[email-masked] -- Speaking for myself only.