[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20120717014558.GA28969@kroah.com>
Date: Mon, 16 Jul 2012 18:45:58 -0700
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: Ming Lei <ming.lei@...onical.com>
Cc: Sebastian Ott <sebott@...ux.vnet.ibm.com>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] driver core: move uevent call to driver_register
On Tue, Jul 17, 2012 at 09:35:02AM +0800, Ming Lei wrote:
> On Tue, Jul 3, 2012 at 1:08 AM, Sebastian Ott <sebott@...ux.vnet.ibm.com> wrote:
>
> > --- a/drivers/base/driver.c
> > +++ b/drivers/base/driver.c
> > @@ -187,6 +187,9 @@ int driver_register(struct device_driver
> > ret = driver_add_groups(drv, drv->groups);
> > if (ret)
> > bus_remove_driver(drv);
> > +
> > + kobject_uevent(&drv->p->kobj, KOBJ_ADD);
>
> You should just send the uevent if 'ret' equals to zero., otherwise
> OOPS may be triggered by kobject_uevent() after the 'drv' has been
> removed.
Ugh, just missed that.
Sebastian, care to send a follow-on patch for this?
thanks,
greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists