Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-25 Thread Gwendal Grignou
Rafael, As you pointed out, ata_tport_delete() should be after scsi_remove_host(), consistent with ata_tport_add() currently before ata_scsi_add_host(). Thanks for fixing it, Gwendal. On Mon, Nov 25, 2013 at 2:41 AM, Rafael J. Wysocki wrote: > > On Monday, November 25, 2013 12:11:54 PM Mika

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-25 Thread Rafael J. Wysocki
On Monday, November 25, 2013 10:29:00 AM James Bottomley wrote: > On Fri, 2013-11-22 at 11:02 -0500, Tejun Heo wrote: > > Hello, > > > > On Fri, Nov 22, 2013 at 08:43:55AM -0700, Bjorn Helgaas wrote: > > > > So, we do have cases where the parent is removed before the child. I > > > > suppose the

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-25 Thread James Bottomley
On Fri, 2013-11-22 at 11:02 -0500, Tejun Heo wrote: > Hello, > > On Fri, Nov 22, 2013 at 08:43:55AM -0700, Bjorn Helgaas wrote: > > > So, we do have cases where the parent is removed before the child. I > > > suppose the parent pci bridge is removed already? AFAICS this > > > shouldn't break

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-25 Thread Rafael J. Wysocki
On Monday, November 25, 2013 12:11:54 PM Mika Westerberg wrote: > On Sun, Nov 24, 2013 at 02:09:09AM +0100, Rafael J. Wysocki wrote: > > On Sunday, November 24, 2013 12:36:03 AM Rafael J. Wysocki wrote: > > > On Saturday, November 23, 2013 03:07:01 PM Greg Kroah-Hartman wrote: > > > > On Sun, Nov

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-25 Thread Mika Westerberg
On Sun, Nov 24, 2013 at 02:09:09AM +0100, Rafael J. Wysocki wrote: > On Sunday, November 24, 2013 12:36:03 AM Rafael J. Wysocki wrote: > > On Saturday, November 23, 2013 03:07:01 PM Greg Kroah-Hartman wrote: > > > On Sun, Nov 24, 2013 at 12:12:59AM +0100, Rafael J. Wysocki wrote: > > > > On

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-25 Thread Mika Westerberg
On Sun, Nov 24, 2013 at 02:09:09AM +0100, Rafael J. Wysocki wrote: On Sunday, November 24, 2013 12:36:03 AM Rafael J. Wysocki wrote: On Saturday, November 23, 2013 03:07:01 PM Greg Kroah-Hartman wrote: On Sun, Nov 24, 2013 at 12:12:59AM +0100, Rafael J. Wysocki wrote: On Saturday,

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-25 Thread James Bottomley
On Fri, 2013-11-22 at 11:02 -0500, Tejun Heo wrote: Hello, On Fri, Nov 22, 2013 at 08:43:55AM -0700, Bjorn Helgaas wrote: So, we do have cases where the parent is removed before the child. I suppose the parent pci bridge is removed already? AFAICS this shouldn't break anything but

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-25 Thread Rafael J. Wysocki
On Monday, November 25, 2013 12:11:54 PM Mika Westerberg wrote: On Sun, Nov 24, 2013 at 02:09:09AM +0100, Rafael J. Wysocki wrote: On Sunday, November 24, 2013 12:36:03 AM Rafael J. Wysocki wrote: On Saturday, November 23, 2013 03:07:01 PM Greg Kroah-Hartman wrote: On Sun, Nov 24, 2013

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-25 Thread Rafael J. Wysocki
On Monday, November 25, 2013 10:29:00 AM James Bottomley wrote: On Fri, 2013-11-22 at 11:02 -0500, Tejun Heo wrote: Hello, On Fri, Nov 22, 2013 at 08:43:55AM -0700, Bjorn Helgaas wrote: So, we do have cases where the parent is removed before the child. I suppose the parent pci

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-25 Thread Gwendal Grignou
Rafael, As you pointed out, ata_tport_delete() should be after scsi_remove_host(), consistent with ata_tport_add() currently before ata_scsi_add_host(). Thanks for fixing it, Gwendal. On Mon, Nov 25, 2013 at 2:41 AM, Rafael J. Wysocki r...@rjwysocki.net wrote: On Monday, November 25, 2013

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-24 Thread Tejun Heo
(cc'ing Gwendal, hi!) On Sun, Nov 24, 2013 at 02:09:09AM +0100, Rafael J. Wysocki wrote: > On Sunday, November 24, 2013 12:36:03 AM Rafael J. Wysocki wrote: > > On Saturday, November 23, 2013 03:07:01 PM Greg Kroah-Hartman wrote: > > > On Sun, Nov 24, 2013 at 12:12:59AM +0100, Rafael J. Wysocki

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-24 Thread Tejun Heo
(cc'ing Gwendal, hi!) On Sun, Nov 24, 2013 at 02:09:09AM +0100, Rafael J. Wysocki wrote: On Sunday, November 24, 2013 12:36:03 AM Rafael J. Wysocki wrote: On Saturday, November 23, 2013 03:07:01 PM Greg Kroah-Hartman wrote: On Sun, Nov 24, 2013 at 12:12:59AM +0100, Rafael J. Wysocki wrote:

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-23 Thread Rafael J. Wysocki
On Sunday, November 24, 2013 12:36:03 AM Rafael J. Wysocki wrote: > On Saturday, November 23, 2013 03:07:01 PM Greg Kroah-Hartman wrote: > > On Sun, Nov 24, 2013 at 12:12:59AM +0100, Rafael J. Wysocki wrote: > > > On Saturday, November 23, 2013 02:53:58 PM Greg Kroah-Hartman wrote: [...] > > > >

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-23 Thread Rafael J. Wysocki
On Saturday, November 23, 2013 03:07:01 PM Greg Kroah-Hartman wrote: > On Sun, Nov 24, 2013 at 12:12:59AM +0100, Rafael J. Wysocki wrote: > > On Saturday, November 23, 2013 02:53:58 PM Greg Kroah-Hartman wrote: > > > On Sat, Nov 23, 2013 at 11:56:48PM +0100, Rafael J. Wysocki wrote: > > > > On

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-23 Thread Greg Kroah-Hartman
On Sun, Nov 24, 2013 at 12:12:59AM +0100, Rafael J. Wysocki wrote: > On Saturday, November 23, 2013 02:53:58 PM Greg Kroah-Hartman wrote: > > On Sat, Nov 23, 2013 at 11:56:48PM +0100, Rafael J. Wysocki wrote: > > > On Friday, November 22, 2013 08:43:55 AM Bjorn Helgaas wrote: > > > > [+cc Rafael,

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-23 Thread Rafael J. Wysocki
On Saturday, November 23, 2013 02:53:58 PM Greg Kroah-Hartman wrote: > On Sat, Nov 23, 2013 at 11:56:48PM +0100, Rafael J. Wysocki wrote: > > On Friday, November 22, 2013 08:43:55 AM Bjorn Helgaas wrote: > > > [+cc Rafael, James] > > > > > > On Tue, Nov 19, 2013 at 11:18 PM, Tejun Heo wrote: > >

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-23 Thread Greg Kroah-Hartman
On Sat, Nov 23, 2013 at 11:56:48PM +0100, Rafael J. Wysocki wrote: > On Friday, November 22, 2013 08:43:55 AM Bjorn Helgaas wrote: > > [+cc Rafael, James] > > > > On Tue, Nov 19, 2013 at 11:18 PM, Tejun Heo wrote: > > > (cc'ing Bjorn) > > > > > > Hello, > > > > > > On Tue, Nov 19, 2013 at

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-23 Thread Rafael J. Wysocki
On Friday, November 22, 2013 08:43:55 AM Bjorn Helgaas wrote: > [+cc Rafael, James] > > On Tue, Nov 19, 2013 at 11:18 PM, Tejun Heo wrote: > > (cc'ing Bjorn) > > > > Hello, > > > > On Tue, Nov 19, 2013 at 03:09:58PM +0200, Mika Westerberg wrote: > >> Commit bcdde7e221a8 (sysfs: make

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-23 Thread Rafael J. Wysocki
On Friday, November 22, 2013 08:43:55 AM Bjorn Helgaas wrote: [+cc Rafael, James] On Tue, Nov 19, 2013 at 11:18 PM, Tejun Heo t...@kernel.org wrote: (cc'ing Bjorn) Hello, On Tue, Nov 19, 2013 at 03:09:58PM +0200, Mika Westerberg wrote: Commit bcdde7e221a8 (sysfs: make

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-23 Thread Greg Kroah-Hartman
On Sat, Nov 23, 2013 at 11:56:48PM +0100, Rafael J. Wysocki wrote: On Friday, November 22, 2013 08:43:55 AM Bjorn Helgaas wrote: [+cc Rafael, James] On Tue, Nov 19, 2013 at 11:18 PM, Tejun Heo t...@kernel.org wrote: (cc'ing Bjorn) Hello, On Tue, Nov 19, 2013 at 03:09:58PM

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-23 Thread Rafael J. Wysocki
On Saturday, November 23, 2013 02:53:58 PM Greg Kroah-Hartman wrote: On Sat, Nov 23, 2013 at 11:56:48PM +0100, Rafael J. Wysocki wrote: On Friday, November 22, 2013 08:43:55 AM Bjorn Helgaas wrote: [+cc Rafael, James] On Tue, Nov 19, 2013 at 11:18 PM, Tejun Heo t...@kernel.org wrote:

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-23 Thread Greg Kroah-Hartman
On Sun, Nov 24, 2013 at 12:12:59AM +0100, Rafael J. Wysocki wrote: On Saturday, November 23, 2013 02:53:58 PM Greg Kroah-Hartman wrote: On Sat, Nov 23, 2013 at 11:56:48PM +0100, Rafael J. Wysocki wrote: On Friday, November 22, 2013 08:43:55 AM Bjorn Helgaas wrote: [+cc Rafael, James]

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-23 Thread Rafael J. Wysocki
On Saturday, November 23, 2013 03:07:01 PM Greg Kroah-Hartman wrote: On Sun, Nov 24, 2013 at 12:12:59AM +0100, Rafael J. Wysocki wrote: On Saturday, November 23, 2013 02:53:58 PM Greg Kroah-Hartman wrote: On Sat, Nov 23, 2013 at 11:56:48PM +0100, Rafael J. Wysocki wrote: On Friday,

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-23 Thread Rafael J. Wysocki
On Sunday, November 24, 2013 12:36:03 AM Rafael J. Wysocki wrote: On Saturday, November 23, 2013 03:07:01 PM Greg Kroah-Hartman wrote: On Sun, Nov 24, 2013 at 12:12:59AM +0100, Rafael J. Wysocki wrote: On Saturday, November 23, 2013 02:53:58 PM Greg Kroah-Hartman wrote: [...] I

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-22 Thread Rafael J. Wysocki
On Friday, November 22, 2013 08:43:55 AM Bjorn Helgaas wrote: > [+cc Rafael, James] > > On Tue, Nov 19, 2013 at 11:18 PM, Tejun Heo wrote: > > (cc'ing Bjorn) > > > > Hello, > > > > On Tue, Nov 19, 2013 at 03:09:58PM +0200, Mika Westerberg wrote: > >> Commit bcdde7e221a8 (sysfs: make

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-22 Thread Tejun Heo
Hello, On Fri, Nov 22, 2013 at 08:43:55AM -0700, Bjorn Helgaas wrote: > > So, we do have cases where the parent is removed before the child. I > > suppose the parent pci bridge is removed already? AFAICS this > > shouldn't break anything but people did seem to expect the removals to > > be

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-22 Thread Bjorn Helgaas
[+cc Rafael, James] On Tue, Nov 19, 2013 at 11:18 PM, Tejun Heo wrote: > (cc'ing Bjorn) > > Hello, > > On Tue, Nov 19, 2013 at 03:09:58PM +0200, Mika Westerberg wrote: >> Commit bcdde7e221a8 (sysfs: make __sysfs_remove_dir() recursive) changed >> the behavior so that directory removals will be

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-22 Thread Bjorn Helgaas
[+cc Rafael, James] On Tue, Nov 19, 2013 at 11:18 PM, Tejun Heo t...@kernel.org wrote: (cc'ing Bjorn) Hello, On Tue, Nov 19, 2013 at 03:09:58PM +0200, Mika Westerberg wrote: Commit bcdde7e221a8 (sysfs: make __sysfs_remove_dir() recursive) changed the behavior so that directory removals

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-22 Thread Tejun Heo
Hello, On Fri, Nov 22, 2013 at 08:43:55AM -0700, Bjorn Helgaas wrote: So, we do have cases where the parent is removed before the child. I suppose the parent pci bridge is removed already? AFAICS this shouldn't break anything but people did seem to expect the removals to be ordered from

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-22 Thread Rafael J. Wysocki
On Friday, November 22, 2013 08:43:55 AM Bjorn Helgaas wrote: [+cc Rafael, James] On Tue, Nov 19, 2013 at 11:18 PM, Tejun Heo t...@kernel.org wrote: (cc'ing Bjorn) Hello, On Tue, Nov 19, 2013 at 03:09:58PM +0200, Mika Westerberg wrote: Commit bcdde7e221a8 (sysfs: make

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-19 Thread Tejun Heo
(cc'ing Bjorn) Hello, On Tue, Nov 19, 2013 at 03:09:58PM +0200, Mika Westerberg wrote: > Commit bcdde7e221a8 (sysfs: make __sysfs_remove_dir() recursive) changed > the behavior so that directory removals will be done recursively. This > means that the sysfs group might already be removed if its

[PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-19 Thread Mika Westerberg
Commit bcdde7e221a8 (sysfs: make __sysfs_remove_dir() recursive) changed the behavior so that directory removals will be done recursively. This means that the sysfs group might already be removed if its parent directory has been removed. The current code outputs warnings similar to following log

[PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-19 Thread Mika Westerberg
Commit bcdde7e221a8 (sysfs: make __sysfs_remove_dir() recursive) changed the behavior so that directory removals will be done recursively. This means that the sysfs group might already be removed if its parent directory has been removed. The current code outputs warnings similar to following log

Re: [PATCH] sysfs: handle duplicate removal attempts in sysfs_remove_group()

2013-11-19 Thread Tejun Heo
(cc'ing Bjorn) Hello, On Tue, Nov 19, 2013 at 03:09:58PM +0200, Mika Westerberg wrote: Commit bcdde7e221a8 (sysfs: make __sysfs_remove_dir() recursive) changed the behavior so that directory removals will be done recursively. This means that the sysfs group might already be removed if its