Re: [PATCH v2 2/2] drivers: core: Remove glue dirs from sysfs earlier

2018-07-10 Thread Benjamin Herrenschmidt
On Tue, 2018-07-10 at 16:55 +0200, Greg Kroah-Hartman wrote: > > > +/** > > + * kobject_has_children - Returns whether a kobject has children. > > + * @kobj: the object to test > > + * > > + * This will return whether a kobject has other kobjects as children. > > + * > > + * It does NOT account

Re: [PATCH v2 2/2] drivers: core: Remove glue dirs from sysfs earlier

2018-07-10 Thread Benjamin Herrenschmidt
On Tue, 2018-07-10 at 16:55 +0200, Greg Kroah-Hartman wrote: > > > +/** > > + * kobject_has_children - Returns whether a kobject has children. > > + * @kobj: the object to test > > + * > > + * This will return whether a kobject has other kobjects as children. > > + * > > + * It does NOT account

Re: [PATCH v2 2/2] drivers: core: Remove glue dirs from sysfs earlier

2018-07-10 Thread Greg Kroah-Hartman
On Tue, Jul 10, 2018 at 10:29:10AM +1000, Benjamin Herrenschmidt wrote: > For devices with a class, we create a "glue" directory between > the parent device and the new device with the class name. > > This directory is never "explicitely" removed when empty however, > this is left to the implicit

Re: [PATCH v2 2/2] drivers: core: Remove glue dirs from sysfs earlier

2018-07-10 Thread Greg Kroah-Hartman
On Tue, Jul 10, 2018 at 10:29:10AM +1000, Benjamin Herrenschmidt wrote: > For devices with a class, we create a "glue" directory between > the parent device and the new device with the class name. > > This directory is never "explicitely" removed when empty however, > this is left to the implicit

Re: [PATCH v2 2/2] drivers: core: Remove glue dirs from sysfs earlier

2018-07-09 Thread Benjamin Herrenschmidt
On Mon, 2018-07-09 at 17:33 -0700, Linus Torvalds wrote: > On Mon, Jul 9, 2018 at 5:29 PM Benjamin Herrenschmidt > wrote: > > > > For devices with a class, we create a "glue" directory between > > the parent device and the new device with the class name. > > > > This directory is never

Re: [PATCH v2 2/2] drivers: core: Remove glue dirs from sysfs earlier

2018-07-09 Thread Benjamin Herrenschmidt
On Mon, 2018-07-09 at 17:33 -0700, Linus Torvalds wrote: > On Mon, Jul 9, 2018 at 5:29 PM Benjamin Herrenschmidt > wrote: > > > > For devices with a class, we create a "glue" directory between > > the parent device and the new device with the class name. > > > > This directory is never

Re: [PATCH v2 2/2] drivers: core: Remove glue dirs from sysfs earlier

2018-07-09 Thread Linus Torvalds
On Mon, Jul 9, 2018 at 5:29 PM Benjamin Herrenschmidt wrote: > > For devices with a class, we create a "glue" directory between > the parent device and the new device with the class name. > > This directory is never "explicitely" removed when empty however, explicitly Is the mis-spelling why

Re: [PATCH v2 2/2] drivers: core: Remove glue dirs from sysfs earlier

2018-07-09 Thread Linus Torvalds
On Mon, Jul 9, 2018 at 5:29 PM Benjamin Herrenschmidt wrote: > > For devices with a class, we create a "glue" directory between > the parent device and the new device with the class name. > > This directory is never "explicitely" removed when empty however, explicitly Is the mis-spelling why

[PATCH v2 2/2] drivers: core: Remove glue dirs from sysfs earlier

2018-07-09 Thread Benjamin Herrenschmidt
For devices with a class, we create a "glue" directory between the parent device and the new device with the class name. This directory is never "explicitely" removed when empty however, this is left to the implicit sysfs removal done by kobject_release() when the object loses its last reference

[PATCH v2 2/2] drivers: core: Remove glue dirs from sysfs earlier

2018-07-09 Thread Benjamin Herrenschmidt
For devices with a class, we create a "glue" directory between the parent device and the new device with the class name. This directory is never "explicitely" removed when empty however, this is left to the implicit sysfs removal done by kobject_release() when the object loses its last reference