[lkml]   [2010]   [Feb]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH] sysfs: differentiate between locking links and non-links
On Wed, Feb 10, 2010 at 11:05 AM, David Rientjes <> wrote:
> On Wed, 10 Feb 2010, Américo Wang wrote:
>> > What happens for hard links such as writing to
>> > /sys/devices/block/xxx/queue/scheduler to change an I/O scheduler which
>> > requires sd->dep_map and sd->parent->dep_map in sysfs_get_active_two() to
>> > pin both?  The call to kobject_del() invokes the destruction that also
>> > requires sd->dep_map in sysfs_deactivate() because of the s_active lockdep
>> > annotation.
>> >
>> This is not related with Neil's case at all.
>> The I/O scheduler switch case should be a bogus, I am working on
>> it. We have more similar cases of cpu hotplug. Trust me, I am working
>> on a fix to all of them, this is not as easy as you may think about.
> You should be able to reuse Neil's sysfs_dirent_init_lockdep(sd, type) to
> seperate the lock classes for the sd getting pinned in
> sysfs_get_active_two() from sysfs_deactivate(), although using subclasses
> would probably be optimal since there is a clear parent -> child relationship.

Yeah, basically, my fix is also adding a separate lockdep class, but
at a different
level. I will send the fix as soon as I finish it.

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2010-02-10 04:17    [W:0.099 / U:23.600 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site