[patch] sched: fix scheduling latencies in NTFS mount

Ingo Molnar
2004-09-14T11:37:56Z

[-- Attachment #1: Type: text/plain, Size: 226 bytes --]

this patch fixes scheduling latencies in the NTFS mount path. We are
dropping the BKL because the code itself is using the ntfs_lock
semaphore which provides safe locking.

has been tested as part of the -VP patchset.

Ingo

[-- Attachment #2: fix-latency-ntfs-mount.patch --]
[-- Type: text/plain, Size: 1174 bytes --]

this patch fixes scheduling latencies in the NTFS mount path. We are
dropping the BKL because the code itself is using the ntfs_lock
semaphore which provides safe locking.

has been tested as part of the -VP patchset.

Signed-off-by: Ingo Molnar <mingo@elte.hu>

--- linux/fs/ntfs/super.c.orig
+++ linux/fs/ntfs/super.c
@@ -29,6 +29,7 @@
#include <linux/buffer_head.h>
#include <linux/vfs.h>
#include <linux/moduleparam.h>
+#include <linux/smp_lock.h>

#include "ntfs.h"
#include "sysctl.h"
@@ -2288,6 +2289,8 @@ static int ntfs_fill_super(struct super_
vol->fmask = 0177;
vol->dmask = 0077;

+ unlock_kernel();
+
/* Important to get the mount options dealt with now. */
if (!parse_options(vol, (char*)opt))
goto err_out_now;
@@ -2424,6 +2427,7 @@ static int ntfs_fill_super(struct super_
}
up(&ntfs_lock);
sb->s_export_op = &ntfs_export_ops;
+ lock_kernel();
return 0;
}
ntfs_error(sb, "Failed to allocate root directory.");
@@ -2527,6 +2531,7 @@ iput_tmp_ino_err_out_now:
}
/* Errors at this stage are irrelevant. */
err_out_now:
+ lock_kernel();
sb->s_fs_info = NULL;
kfree(vol);
ntfs_debug("Failed, returning -EINVAL.");