[eepro100] Receive Buffer Descriptors

Donald Becker becker@scyld.com
Thu, 3 Aug 2000 11:17:44 -0400 (EDT)


On Thu, 3 Aug 2000, Naga R Narayanaswamy wrote:

> >> In the flexible model, the first RFD has a linked list of RBD's,
> >> and subsequent RFD's have the RBD address set to NULL.
> >> In other words only the first RFD can have RBDs.
> 
> >The first RFD points to all of the buffers.
> >Using this model requires the chip to do extra PCI bus transactions,
> and the
> >driver has to do extra housekeeping.
> 
> My understanding is one RFD is used for one ethernet frame received.
> (For the sake of easiness assume one buffer holds a complete
> ethernet frame). So, in flexible model, if the first frame is received
> in first RFD where do the subsequent frames go ?? If they go to the
> next RFD's we do not have RBD's associated from them.

The chip handles the association internally.  The driver knows how the chip
operates, and thus can calculate which RBD goes with which RFD.

Yes, it is complex, and you have to count on the chip doing exactly what you
expect.

This model is intended to be used when the RBDs are small e.g. 128 bytes
each.  This minimizes the "wasted" space of full-packet-sized buffers, at
the cost of following a lot of pointer.  This was a good tradeoff a decade
ago when chaches were uncommon and pointer following was cheap.


> I have a chain of RFD's but I still do not get the point
> why only first RFD point to the buffers (I may have only one
> if the buffer is capable of holding a complete ethernet frame)
> and the subsequent RFD's has no buffers.

Think of it this way: the chip needs a list of RFDs, and a list of RBDs.
Rather than passing two list pointers to the chip, you pass only the pointer
to the RFD.

> I am coming from a 21143 world where, each rx descriptor
> has a pointer to a buffer.

The data handling of the 21143 is a much cleaner design.  That's why it's so
widely copied.  You don't see anyone making chips similar to the eepro100,
do you?


Donald Becker				becker@scyld.com
Scyld Computing Corporation		http://www.scyld.com
410 Severn Ave. Suite 210		Beowulf-II Cluster Distribution
Annapolis MD 21403