diff options
author | Arnd Bergmann <arnd@arndb.de> | 2010-10-04 16:55:57 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-10-05 12:08:21 -0400 |
commit | 2116b7a473bf1c8d26998b477c294e7fe294921f (patch) | |
tree | 5f06aca6b425916f763d83fa4516bca51c8f9a60 /fs/smbfs/ioctl.c | |
parent | 5af74aa5e97fcc0cc3955bc2a7ff6f3a13fa41cb (diff) |
smbfs: move to drivers/staging
smbfs has been scheduled for removal in 2.6.27, so
maybe we can now move it to drivers/staging on the
way out.
smbfs still uses the big kernel lock and nobody
is going to fix that, so we should be getting
rid of it soon.
This removes the 32 bit compat mount and ioctl
handling code, which is implemented in common fs
code, and moves all smbfs related files into
drivers/staging/smbfs.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'fs/smbfs/ioctl.c')
-rw-r--r-- | fs/smbfs/ioctl.c | 69 |
1 files changed, 0 insertions, 69 deletions
diff --git a/fs/smbfs/ioctl.c b/fs/smbfs/ioctl.c deleted file mode 100644 index 07215312ad39..000000000000 --- a/fs/smbfs/ioctl.c +++ /dev/null | |||
@@ -1,69 +0,0 @@ | |||
1 | /* | ||
2 | * ioctl.c | ||
3 | * | ||
4 | * Copyright (C) 1995, 1996 by Volker Lendecke | ||
5 | * Copyright (C) 1997 by Volker Lendecke | ||
6 | * | ||
7 | * Please add a note about your changes to smbfs in the ChangeLog file. | ||
8 | */ | ||
9 | |||
10 | #include <linux/errno.h> | ||
11 | #include <linux/fs.h> | ||
12 | #include <linux/ioctl.h> | ||
13 | #include <linux/time.h> | ||
14 | #include <linux/mm.h> | ||
15 | #include <linux/highuid.h> | ||
16 | #include <linux/smp_lock.h> | ||
17 | #include <linux/net.h> | ||
18 | |||
19 | #include <linux/smb_fs.h> | ||
20 | #include <linux/smb_mount.h> | ||
21 | |||
22 | #include <asm/uaccess.h> | ||
23 | |||
24 | #include "proto.h" | ||
25 | |||
26 | long | ||
27 | smb_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) | ||
28 | { | ||
29 | struct smb_sb_info *server = server_from_inode(filp->f_path.dentry->d_inode); | ||
30 | struct smb_conn_opt opt; | ||
31 | int result = -EINVAL; | ||
32 | |||
33 | lock_kernel(); | ||
34 | switch (cmd) { | ||
35 | uid16_t uid16; | ||
36 | uid_t uid32; | ||
37 | case SMB_IOC_GETMOUNTUID: | ||
38 | SET_UID(uid16, server->mnt->mounted_uid); | ||
39 | result = put_user(uid16, (uid16_t __user *) arg); | ||
40 | break; | ||
41 | case SMB_IOC_GETMOUNTUID32: | ||
42 | SET_UID(uid32, server->mnt->mounted_uid); | ||
43 | result = put_user(uid32, (uid_t __user *) arg); | ||
44 | break; | ||
45 | |||
46 | case SMB_IOC_NEWCONN: | ||
47 | /* arg is smb_conn_opt, or NULL if no connection was made */ | ||
48 | if (!arg) { | ||
49 | result = 0; | ||
50 | smb_lock_server(server); | ||
51 | server->state = CONN_RETRIED; | ||
52 | printk(KERN_ERR "Connection attempt failed! [%d]\n", | ||
53 | server->conn_error); | ||
54 | smbiod_flush(server); | ||
55 | smb_unlock_server(server); | ||
56 | break; | ||
57 | } | ||
58 | |||
59 | result = -EFAULT; | ||
60 | if (!copy_from_user(&opt, (void __user *)arg, sizeof(opt))) | ||
61 | result = smb_newconn(server, &opt); | ||
62 | break; | ||
63 | default: | ||
64 | break; | ||
65 | } | ||
66 | unlock_kernel(); | ||
67 | |||
68 | return result; | ||
69 | } | ||