[OpenAFS] Re: afs.GCPAGs in current releases under Linux (RHEL4/5)

Andrew Deason adeason@sinenomine.net
Fri, 5 Mar 2010 13:12:17 -0600


On Fri, 5 Mar 2010 19:03:19 +0000
Simon Wilkinson <sxw@inf.ed.ac.uk> wrote:

> > Could we remove the unixuser from the list in afs_PutUser if the
> > refCount drops to zero (possibly only under the same conditions as
> > the checks in afs_GCUserData)? I'm not sure I get the rationale for
> > having a separate occasional GC for the linked list.
> 
> We need to be very careful what we do in afs_pag_destroy(), as we
> don't have much control over the context in which it's called. In
> theory, we shouldn't do anything that sleeps - our caller may hold a
> spinlock. I'd be very wary of adding additional logic to that code,
> unless we change the way that the user list is protected.

Okay, but how about signalling something else to do the cleanup, then?
Say, afs_Daemon (if it has nothing better to do) could unlink the marked
unixuser(s) for us. It could just check a list of unixusers to unlink or
something on each iteration, instead of GC'ing in the ten minute check.

-- 
Andrew Deason
adeason@sinenomine.net