On Thu, Jul 03, 2008 at 01:27:00PM -0400, Dmitry Torokhov wrote: > Hi John, > > On Thu, Jul 03, 2008 at 09:42:31AM -0700, John Linn wrote: > > + > > + /* Initialize the PS/2 interface */ > > + mutex_lock(&drvdata->cfg_mutex); > > + if (xps2_initialize(drvdata)) { > > + mutex_unlock(&drvdata->cfg_mutex); > > + dev_err(dev, "Could not initialize device\n"); > > + retval = -ENODEV; > > + goto failed3; > > + } > > + mutex_unlock(&drvdata->cfg_mutex); > > The drvdata is allocated per-port and so both (there are 2 PS/2 ports, > right?) ports get their own copy of cfg_mutex. Since you are trying to > serialze access to resource shared by both ports it will not work. > The original driver-global mutex was appropriate (the only thing I > objected there was use of a counting semaphore instead of a mutex). John, correct me if I'm wrong, but I don't think there are any shared resources being accessed here and I believe the mutex is entirely unnecessary. Cheers, g. -- To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html