On Tue, Mar 25, 2008 at 01:03:03PM -0700, Dan Price wrote:

> Can you/have you file appropriate bugs against ON to go along with this
> fix?

Not yet; I'll do that.

> In "perms" the author gets to (must?) omit the name of the driver; in
> clone_perms, it must be specified (since it names a minor node).  But
> AFAIK that's essentially a constant, and the clone minor name will always
> match the driver name.  Is that the case?

It's certainly the case for all the drivers in Indiana, but I don't know if
it always holds true.  I'll ping Jerry or Ed, see if they know any more.

> I see two possible remedies here: get rid of clone_perms and make this
> generic:
> 
> add driver name=dmfe perms="dmfe:* 0666 root sys" perms="clone:dmfe 0666 root 
> sys

I don't like this, because it means I have to specially test for "clone" in
the driver action.  Yes, I know it's essentially equivalent to having a new
attribute, but I think the latter is cleaner.

> Or, in the clone action, presume that <drivername> is the node of the
> clone driver you're talking about:
> 
> add driver name=dmfe perms="* 0666 root sys" clone_perms="0666 root sys"

I think I'd considered this, and rejected it because I wasn't sure if it
would *always* match (or if there might ever be a case where a driver would
deliver the clone perm for more than one minor node name).  If I can
confirm that assumption, I'll change the code.

> It seems like there might be a useful opportunity to make a shortcut
> here, BTW.   Something like network_drvperms="default" which would
> auto-expand to the obvious defaults.

That'd be a great idea, but I think it's more in the realm of a build
system that provides the cpp macro or whatever to do that expansion.  I
don't think that's appropriate for the packaging system itself.

Thanks,
Danek
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss

Reply via email to