I'm sponsoring this fasttrack on behalf of Cathy Zhou and the Clearview
team. The timer expires on January 10th 2008.
1. Summary
This case comprises pre-integration updates to Clearview Nemo
Unification and Vanity Naming (a.k.a. UV), currently described in the
following PSARC cases:
2006/499 Clearview Nemo unification and vanity naming
2007/527 Addendum for Clearview Vanity Naming and Nemo Unification
An updated UV design document is included in the case materials.
2. Details
2.1 Removal of Data Fast-Path for Softmac
In the design described in 2006/499, the softmac kernel module is
responsible for representing "legacy" DLPI devices to the Nemo
framework, and ensuring that data packets flow properly between DLPI
streams above Nemo and the "legacy" drivers underneath. This called
for a fast-path between upper DLPI streams and lower "legacy" drivers,
implemented by having the softmac module open a stream to the
underlying driver for each upper stream above Nemo, and linking these
streams to bypass Nemo entirely. The fast-path is referred to as the
"perstream" past-path in the design document.
This fast-path has been removed in the final phases of development due
to to its incompatibility with an upcoming project which is making
major changes in the same area of the kernel. For the initial UV
putback, data packets will flow through the Nemo framework as with any
other Nemo driver. We are actively working with the other project on
an alternate fastpath implementation that meets everyone's needs, and
its architecture will be part of a future case.
The result is that the following interfaces will _not_ be delivered by
the UV putback as initially specified by the stated PSARC cases:
* MAC_CAPAB_TX_LOOPBACK (2006/499, Project Private)
* MAC_CAPAB_PUTNEXT_TX (2006/499, Project Private)
* MAC_CAPAB_MDT (2006/499, Project Private)
* MAC_CAPAB_PERSTREAM (2006/499, Project Private)
* mac_perstream_open() and mac_perstream_close() (2006/499, Project
Private)
2.2 MAC_CAPAB_LEGACY MAC Capability (Project Private)
This capability replaces MAC_CAPAB_NOLINK_UPDATE defined in 2006/499,
and provides additional information. The data for this capability is
a pointer to the following structure:
typedef struct mac_capab_legacy_s {
dev_t ml_dev;
uint32_t ml_unsup_note;
} mac_capab_legacy_t;
The ml_dev field is set to the dev_t of the underlying "legacy"
device. This is used by the mac module to force the underlying device
to attach when a MAC client calls mac_open().
The ml_unsup_note field is a bitfield of DLPI notifications. Certain
"legacy" devices under softmac may not support the DLPI notifications
needed for softmac to provide all MAC notifications to the Nemo
framework. The softmac module fills in this field with the set of
DLPI notifications that are not supported by the given softmac
instance.
2.3 MAC_CAPAB_NO_ZCOPY
The MAC_CAPAB_NOZCOPY MAC capability defined in 2006/499 is being
renamed by this case to MAC_CAPAB_NO_ZCOPY to be consistent with other
capability nomenclature.
2.4 Privileges for dlmgmtd
The dlmgmtd daemon described in 2006/499 requires the following set of
privileges: file_dac_write, file_chown_self, sys_mount, and
sys_net_config.
2.5 MAXLINKNAMELEN
The MAXLINKNAMELEN constant has been added to <sys/param.h>, and it
defines the longest possible permitted datalink name (including the
terminating NULL character.) Its stability level is Committed.
Note that the existing DLPI_LINKNAME_MAX constant remains, but it only
intended for use by libdlpi consumers, whereas MAXLINKNAMELEN is
appropriate for more general use.
2.6 New mac_margin_update() MAC driver function
2007/527 described a m_margin field of mac_register_t for MAC drivers
to specify a margin value. To dynamically update this value, this
case adds the following Consolidation Private MAC driver function:
boolean_t mac_margin_update(mac_handle_t, uint32_t);
The second argument specifies the new margin value. If the margin
cannot be changed to the specified value, B_FALSE is returned,
otherwise B_TRUE is returned. B_FALSE would be returned, for example,
if a MAC client has placed a constraint on the MAC's margin such that
it cannot be increased to the specified value (see mac_margin_add() in
section 2.7).
2.7 New Nemo MAC client functions
In addition to the existing mac_open() function which allows MAC
clients to open a specific MAC by MAC name, UV introduces the
following functions to allow clients to open a MAC using different
identifiers which may be available to MAC clients:
int mac_open_by_linkid(datalink_id_t, mac_handle_t *);
int mac_open_by_linkname(const char *, mac_handle_t *);
mac_open_by_linkid() allows a client to open a MAC using the linkid of
the link above the MAC, and mac_open_by_linkname() allows a client to
open a MAC using the link name of the link above the MAC.
Because the MAC margin size can dynamically change as described in
2.6, MAC clients also need a way to specify their constraints on the
"margin" that drivers can provide (because proper operation MAC
clients could depend on a specific margin size previously set by the
driver.) To request that the MAC not change its margin size to be
less than a specific value, MAC clients call the following function:
int mac_margin_add(mac_handle_t, uint32_t *, boolean_t);
If the third argument is set to B_TRUE, then the caller requires that
the margin remain at or above the current value, and the second
argument is set to the current value. If B_FALSE, the second argument
specifies a specific value that the caller requires to be the minimum
margin.
To remove a constraint on margin size, MAC clients call the following
function:
int mac_margin_remove(mac_handle_t, uint32_t);
The last argument specifies the value to be removed as a constraint.
As with the rest of the Nemo MAC client interfaces, all of these
interfaces are private to the Nemo framework (Project Private).
2.8 Change to dls_create() and dls_destroy()
The Nemo Project Private dls_create() and dls_destroy() functions have
been renamed dls_devnet_create() and dls_devnet_destroy()
respectively. See the UV design document for details.
2.9 linkid management API changes
The Project Private linkid management API described in 2006/499
defined a function called dladm_rename_conf(). It has been determined
that this function is not needed, and it will not be included.
Additional minor changes have been made to this API, specifically to
the following functions:
dladm_status_t dladm_get_conf_field(dladm_conf_t, const char *,
void *, size_t);
dladm_status_t dladm_set_conf_field(dladm_conf_t, const char *,
dladm_datatype_t, const void *);
The "dladm_datatype_t *" argument was removed from
dladm_get_conf_field(), and the last argument of
dladm_set_conf_field() was changed from "void *" to "const void *".
2.10 dladm parseable output
The format of parseable output of dladm show-* subcommands is
currently not consistent (different subcommands have a different
output formats.) A preferred output format is currently used by
show-wifi, scan-wifi, show-secobj, and show-linkprop. In order to
bring uniformity across all show-* parseable output, this case makes
the other show-* subcommands' parseable output conform to that format.
It is:
<key>="<value>" [<key>="<value>" ...]
Every value is explicitly quoted to better support values with
embedded space characters, and preceded by a <key>= identifier string.