> That issue is trivially solved by using smf instances as I suggested --
 > if every datalink has its own instance (think "network/datalink:foo0")
 > then by definition of the single FMRI namespace no one can create
 > another instance "foo0" and you don't need to write any code to
 > enforce that because smf enforces it by design.

[ I fear I've misunderstood what you're suggesting. ]

I don't see how that solves the problem.  Suppose a new network device is
attached and the driver's attach() routine is called, which then calls
mac_register() or whatever to drive the creation of the link.  As part of
that, a new link is going to be instantiated, which will need a new unique
link identifier.  How will the kernel know what link identifier it can use
for that without knowing what link identifiers are associated with
temporarily deleted links?  Of course, if we track all link identifiers
(even deleted ones) in the kernel, then we can do that, but then we're
back to tracking state that is not otherwise relevant :-/

Also, another core piece of the current design is that the bindings of
link identifiers to link names are persistent across reboots.  So even if
we tracked them in the kernel, we'd need to commit them to stable storage
across a reboot.

-- 
meem

Reply via email to