2009/235 dladm Possible Values List
James Carlson
james.d.carlson at sun.com
Mon Apr 13 11:28:59 PDT 2009
Girish Moodalbail writes:
> For such drivers, which do not support "possible" values for the MTU
> property, the <drv>_m_getprop() would return 'ENOTSUP' and we would
> display the current value of the MTU (as cached by MAC layer) in the output.
>
> bash-3.2$ dladm show-linkprop -p mtu mxfe0
> LINK PROPERTY VALUE DEFAULT POSSIBLE
> mxfe0 mtu 1500 1500 1500
>
> The meaning of 'possible' value, from dladm(1m) man page, is 'list of
> values the property can have' and in this case it will be 1500.
One of the subtleties of this project is this section:
NOTE: MAC_PROP_POSSIBLE flag needs to be handled 'carefully'.
The reason this project doesn't have to modify every GLDv3 driver is
that the property in question is not one that drivers actually
return. Everyone who has a settable MTU has <name>_m_setprop set up
to handle MAC_PROP_MTU, but nobody has <name>_m_getprop for this,
because MTU is special-cased in mac_get_prop().
If it were otherwise -- that is, if this were a "normal" property and
not special-cased in mac_get_prop -- then the proposed design would
require changing all the drivers.
The next person who wants to extend this (using MAC_PROP_POSSIBLE for
some other property) may well have to bite that bullet.
--
James Carlson, Solaris Networking <james.d.carlson at sun.com>
Sun Microsystems / 35 Network Drive 71.232W Vox +1 781 442 2084
MS UBUR02-212 / Burlington MA 01803-2757 42.496N Fax +1 781 442 1677
More information about the opensolaris-arc
mailing list