Re: Half Duplex and Zero Copy IP

From: Jamie Lokier (lk@tantalophile.demon.co.uk)
Date: Fri Aug 10 2001 - 18:50:37 EST


Andi Kleen wrote:
> The sniffer zero copy implementation as implemented in some libpcaps
> does not depend on any special NIC support; it should work with any.

Do you mean mmap() on a packet socket? Unless I am mistaken, the data
is still copied once to the mmap area, however only the capture length
is copied -- the rest of the packet is discarded.

This means that you cannot use mmap() on a packet socket to zero-copy
read whole packets. In fact there is no way to zero-copy read whole
packets into user space, without modifying the kernel.

Am I mistaken (it would be nice)?

Thanks,
-- Jamie
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Wed Aug 15 2001 - 21:00:36 EST