Re: [patch 2.6.15-mm4] sem2mutex: drivers/input/, #2

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

 



On Sat, 2006-01-14 at 11:43 -0500, Dmitry Torokhov wrote:
> On Saturday 14 January 2006 11:21, Faidon Liambotis wrote:
> > Ingo Molnar wrote:
> > > @@ -1371,11 +1373,11 @@ static ssize_t psmouse_attr_set_protocol
> > >  			return -EIO;
> > >  		}
> > >  
> > > -		up(&psmouse_sem);
> > > +		mutex_unlock(&psmouse_mutex);
> > >  		serio_unpin_driver(serio);
> > >  		serio_unregister_child_port(serio);
> > >  		serio_pin_driver_uninterruptible(serio);
> > > -		down(&psmouse_sem);
> > > +		mutex_lock(&psmouse_mutex);
> > Isn't that supposed to be the other way around?
> > 
> 
> No, that's correct. We temporarily dropping the lock to let the serio core
> do its job and then reaqcuire it again to finish what we were doing. 

are you REALLY sure? It looks to me as if this function is called from
sysfs.. so you don't know that you have the lock...


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux