PSARC 2007/229 add afe driver to Solaris (update)
Garrett D'Amore
Garrett.Damore at Sun.COM
Mon Jul 23 23:52:13 PDT 2007
I would like to update this case, as we have decided to deliver a GLDv3
version of the afe driver instead of GLDv2. This has many benefits,
which the ARC is probably well familiar with so I will not expand upon
them here.
This means that the driver will not import the GLDv2 interfaces, but
will import the Consolidation Private GLDv3 interfaces.
I am also importing the MII register definitions (macros) that are in
sys/miiregs.h. I do not believe that this header file has ever been
properly ARC'd, but since the values are all macro definitions for
constant values, it should not cause any binary compatibility issues.
The file was noted in PSARC 2002/711, but no stability classification
was identified. (Note that the rge, bge, and dmfe drivers also depend
on this header, as do a few closed source drivers.)
Also, as part of this work, I've updated the driver to perform loan-up
of DMA buffers, and to attempt to use zero-copy DMA for transmit
buffers. To facilitate tweaking of this, there are three new
undocumented tunables (accessible via either ndd or driver.conf.) I do
not plan on documenting these at this point. Here are the descriptions
of them:
tx_max_bcopy - transmit mblks smaller than this will not be DMA'd,
but will be bcopy()'d into a premapped DMA buffer (default = 256)
rx_max_bcopy - receive packets smaller than this will not be loaned
up, but will be bcopy()'d into a freshly allocb()'d buffer (default = 256)
rx_max_loanup - maximum number of outstanding packets that will be
loaned up to the upper stack without bcopy'ing (default = 128)
Tuning these would be either for performance tweaking (which we don't
expect to be necessary), or (in the case of rx_max_loanup) to prevent
the upper layers from holding mblks. (Setting rx_max_loanup == 0 may
facilitate DDI detach, since the driver will refuse to detach while the
upper layers are holding message blocks that have been loaned up... as
the device's instance is required to properly tear down the DMA bindings
for those buffers. Note that the device is normally DR safe, although
IPv6 in.ndpd seems to like to hold on to received mblks perhaps longer
than it should.)
In the future we hope these tunables will be handled via the Brussels
framework.
-- Garrett
More information about the opensolaris-arc
mailing list