DragonFly submit List (threaded) for 2008-02
DragonFly BSD
DragonFly submit List (threaded) for 2008-02
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: lockmgr_sleep() (was Re: ssleep() (was Re: mention msleep() in porting_drivers.txt))


From: Aggelos Economopoulos <aoiko@xxxxxxxxxxxxxx>
Date: Sun, 10 Feb 2008 14:16:14 +0200

On Sunday 10 February 2008, Simon 'corecode' Schubert wrote:
> Aggelos Economopoulos wrote:
> > diff -u -p -r1.88 kern_synch.c
> > --- sys/kern/kern_synch.c
> > +++ sys/kern/kern_synch.c
> > @@ -587,6 +587,29 @@ tsleep_interlock(void *ident)
> >  }
> >  
> >  /*
> > + * Atomically drop a lockmgr lock and go to sleep. The lock is reacquired
> > + * before returning from this function. Passes on the value returned by
> > + * tsleep().
> > + */
> > +int
> > +lock_sleep(void *ident, int flags, const char *wmesg, int timo,
> > +	   struct lock *lk)
> 
> I like it, but I'd put lock_sleep in kern_lock.c and wouldn't make 
> lockstatus_owned public.

No problem with that.

> +10, should go in now.  However then we'd ship a release with a lot of 
> deprecation warnings.  Maybe we should follow up with a msleep->spin_sleep 
> commit.

That was my intention. find + multiline regular expression should help.

Aggelos



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]