aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ocfs2
diff options
context:
space:
mode:
authorAndi Kleen <ak@suse.de>2008-01-26 21:17:17 -0500
committerMark Fasheh <mfasheh@suse.com>2008-04-18 11:56:11 -0400
commitc9ec14884d69a303eef4faae42bd3c4e25b19941 (patch)
tree50ed19faff3fbaaab8dfa872b506501a24826df3 /fs/ocfs2
parent5dabd69515765156605b09261abf969236a77803 (diff)
ocfs2: Convert ocfs2 over to unlocked_ioctl
As far as I can see there is nothing in ocfs2_ioctl that requires the BKL, so use unlocked_ioctl Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Mark Fasheh <mfasheh@suse.com>
Diffstat (limited to 'fs/ocfs2')
-rw-r--r--fs/ocfs2/file.c4
-rw-r--r--fs/ocfs2/ioctl.c12
-rw-r--r--fs/ocfs2/ioctl.h3
3 files changed, 6 insertions, 13 deletions
diff --git a/fs/ocfs2/file.c b/fs/ocfs2/file.c
index ed5d5232e85d..9154c82d3258 100644
--- a/fs/ocfs2/file.c
+++ b/fs/ocfs2/file.c
@@ -2242,7 +2242,7 @@ const struct file_operations ocfs2_fops = {
2242 .open = ocfs2_file_open, 2242 .open = ocfs2_file_open,
2243 .aio_read = ocfs2_file_aio_read, 2243 .aio_read = ocfs2_file_aio_read,
2244 .aio_write = ocfs2_file_aio_write, 2244 .aio_write = ocfs2_file_aio_write,
2245 .ioctl = ocfs2_ioctl, 2245 .unlocked_ioctl = ocfs2_ioctl,
2246#ifdef CONFIG_COMPAT 2246#ifdef CONFIG_COMPAT
2247 .compat_ioctl = ocfs2_compat_ioctl, 2247 .compat_ioctl = ocfs2_compat_ioctl,
2248#endif 2248#endif
@@ -2258,7 +2258,7 @@ const struct file_operations ocfs2_dops = {
2258 .fsync = ocfs2_sync_file, 2258 .fsync = ocfs2_sync_file,
2259 .release = ocfs2_dir_release, 2259 .release = ocfs2_dir_release,
2260 .open = ocfs2_dir_open, 2260 .open = ocfs2_dir_open,
2261 .ioctl = ocfs2_ioctl, 2261 .unlocked_ioctl = ocfs2_ioctl,
2262#ifdef CONFIG_COMPAT 2262#ifdef CONFIG_COMPAT
2263 .compat_ioctl = ocfs2_compat_ioctl, 2263 .compat_ioctl = ocfs2_compat_ioctl,
2264#endif 2264#endif
diff --git a/fs/ocfs2/ioctl.c b/fs/ocfs2/ioctl.c
index ab1c2167d7f4..b413166dd163 100644
--- a/fs/ocfs2/ioctl.c
+++ b/fs/ocfs2/ioctl.c
@@ -113,9 +113,9 @@ bail:
113 return status; 113 return status;
114} 114}
115 115
116int ocfs2_ioctl(struct inode * inode, struct file * filp, 116long ocfs2_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
117 unsigned int cmd, unsigned long arg)
118{ 117{
118 struct inode *inode = filp->f_path.dentry->d_inode;
119 unsigned int flags; 119 unsigned int flags;
120 int new_clusters; 120 int new_clusters;
121 int status; 121 int status;
@@ -169,9 +169,6 @@ int ocfs2_ioctl(struct inode * inode, struct file * filp,
169#ifdef CONFIG_COMPAT 169#ifdef CONFIG_COMPAT
170long ocfs2_compat_ioctl(struct file *file, unsigned cmd, unsigned long arg) 170long ocfs2_compat_ioctl(struct file *file, unsigned cmd, unsigned long arg)
171{ 171{
172 struct inode *inode = file->f_path.dentry->d_inode;
173 int ret;
174
175 switch (cmd) { 172 switch (cmd) {
176 case OCFS2_IOC32_GETFLAGS: 173 case OCFS2_IOC32_GETFLAGS:
177 cmd = OCFS2_IOC_GETFLAGS; 174 cmd = OCFS2_IOC_GETFLAGS;
@@ -191,9 +188,6 @@ long ocfs2_compat_ioctl(struct file *file, unsigned cmd, unsigned long arg)
191 return -ENOIOCTLCMD; 188 return -ENOIOCTLCMD;
192 } 189 }
193 190
194 lock_kernel(); 191 return ocfs2_ioctl(file, cmd, arg);
195 ret = ocfs2_ioctl(inode, file, cmd, arg);
196 unlock_kernel();
197 return ret;
198} 192}
199#endif 193#endif
diff --git a/fs/ocfs2/ioctl.h b/fs/ocfs2/ioctl.h
index 4d6c4f430d0d..cf9a5ee30fef 100644
--- a/fs/ocfs2/ioctl.h
+++ b/fs/ocfs2/ioctl.h
@@ -10,8 +10,7 @@
10#ifndef OCFS2_IOCTL_H 10#ifndef OCFS2_IOCTL_H
11#define OCFS2_IOCTL_H 11#define OCFS2_IOCTL_H
12 12
13int ocfs2_ioctl(struct inode * inode, struct file * filp, 13long ocfs2_ioctl(struct file *filp, unsigned int cmd, unsigned long arg);
14 unsigned int cmd, unsigned long arg);
15long ocfs2_compat_ioctl(struct file *file, unsigned cmd, unsigned long arg); 14long ocfs2_compat_ioctl(struct file *file, unsigned cmd, unsigned long arg);
16 15
17#endif /* OCFS2_IOCTL_H */ 16#endif /* OCFS2_IOCTL_H */