On Thu 02 Oct 2008 at 04:10PM, Danek Duvall wrote:
> On Thu, Oct 02, 2008 at 03:53:53PM -0700, Dan Price wrote:
>
> > When you add the devlink entry, I notice that there is checking for
> > dups, and no dups are added. When the package is removed, that will
> > presumably nuke the devlinks and when the second package is removed,
> > we'll emit the warning you added. I was wondering if it might make
> > sense to actually stick the dup entries into the file and in the remove
> > logic, take care to only remove one instance of the entry. That would
> > effectively do the reference counting you'd want, and presumably
> > wouldn't hurt. You'd have to see if the kernel tolerates it.
>
> How would I test that substantially? Could the behavior be driver
> dependent?
Put two lines into devlink.tab and see what happens? My cursory
look at the devfsadm source leads me to a hypothesis that it would
be harmless-- you could dump out its devlinktab_list data structure
to see if it looks sane. I would also consult with Jan to make sure
that this is acceptable to him. I don't think the behaviour would be
driver dependent, as only devfsadm knows about devlink.tab... it is not
read by the kernel AFAIK (unless /dev-fs changed that...).
It's a total edge case. If you don't want to deal, that's fine.
There are very few devlink.tab entries out there in the world.
> Looks like there's one instance where I forgot to put a read of the file
> inside a try/catch, so I'll fix that up. In all other cases (and if we get
> any other errors during install or removal), we print a message and bail
> out.
Please add a test case if possible.
-dp
--
Daniel Price - Solaris Kernel Engineering - [EMAIL PROTECTED] - blogs.sun.com/dp
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss