On Fri, Jan 23, 2009 at 03:24:34PM +0100, Jean Delvare wrote: > > diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c-core.c > > index b1c9abe..3454878 100644 > > --- a/drivers/i2c/i2c-core.c > > +++ b/drivers/i2c/i2c-core.c > > @@ -799,10 +799,10 @@ void i2c_del_driver(struct i2c_driver *driver) > > class_for_each_device(&i2c_adapter_class, NULL, driver, > > __detach_adapter); > > > > + mutex_unlock(&core_lock); > > + > > driver_unregister(&driver->driver); > > pr_debug("i2c-core: driver [%s] unregistered\n", > > driver->driver.name); > > - > > - mutex_unlock(&core_lock); > > } > > EXPORT_SYMBOL(i2c_del_driver); > > What tree is this patch against? I can't get it to apply on top of > 2.6.29-rc2. It was against 2.6.29-rc2... let me attach a patch file, maybe I did cut&paste. :) Ciao, Rodolfo -- GNU/Linux Solutions e-mail: giometti@xxxxxxxxxxxx Linux Device Driver giometti@xxxxxxxx Embedded Systems phone: +39 349 2432127 UNIX programming skype: rodolfo.giometti
diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c-core.c index b1c9abe..3454878 100644 --- a/drivers/i2c/i2c-core.c +++ b/drivers/i2c/i2c-core.c @@ -799,10 +799,10 @@ void i2c_del_driver(struct i2c_driver *driver) class_for_each_device(&i2c_adapter_class, NULL, driver, __detach_adapter); + mutex_unlock(&core_lock); + driver_unregister(&driver->driver); pr_debug("i2c-core: driver [%s] unregistered\n", driver->driver.name); - - mutex_unlock(&core_lock); } EXPORT_SYMBOL(i2c_del_driver);