Messages in this thread | | | Subject | Re: Buffering packets in network driver (qdisc?) | Date | Sun, 15 Aug 1999 00:57:26 +0100 (BST) | From | Alan Cox <> |
| |
> the packets arrive from the network layer, I need to hold them > until this message is received.
This is fine. Be aware that if the message is issued from the context of a typical socket sender you must avoid deadlocks - ie holding the memory your magic message will come from.
> Is there a way to have the network layer buffer them and allow > the driver to extract them on demand. In dev.c it talks about > enqueue to do with the QoS stuff. Could this be used? Any > references?
If you set dev->tbusy and refuse packets they will be queued for you and eventually spilled if you get too much congestion. When the interrupt occurs you can then dev->tbusy=0; mark_bh(NET_BH) and it will let rip.
To reduce latency if this is an issue, remember one buffer in the card driver itself and when the magic message occurs send this first buffer as well.
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |