Re: [PATCH 2/3] sysfs: Fix and sysfs_mv_dir by using lock_rename.

From: Dave Hansen
Date: Tue Oct 07 2008 - 17:24:45 EST


On Tue, 2008-10-07 at 03:51 -0700, Eric W. Biederman wrote:
> sysfs_mv_dir picks an arbitrary mutex lock ordering and busy waits
> until it can grab the inode mutexes in that order. This can dead lock
> on UP systems.
>
> Instead use the generic lock_rename that guarantees we grab parent
> directories before child directories, so there is not need to spin and
> no chance of deadlock.

This is a vast improvement over what was there before. Nice!

-- Dave

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/