cifs: warn about impending deprecation of legacy MultiuserMount code
authorJeff Layton <jlayton@redhat.com>
Tue, 17 Jan 2012 21:09:15 +0000 (16:09 -0500)
committerSteve French <smfrench@gmail.com>
Wed, 18 Jan 2012 04:40:31 +0000 (22:40 -0600)
We'll allow a grace period of 2 releases (3.3 and 3.4) and then remove
the legacy code in 3.5.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <smfrench@gmail.com>
fs/cifs/cifs_debug.c

index 84e8c0724704173669659f899e7cc83c6741b857..24b3dfc05282e2214df5f3eb014eb124651d6ffe 100644 (file)
@@ -676,14 +676,23 @@ static ssize_t cifs_multiuser_mount_proc_write(struct file *file,
 {
        char c;
        int rc;
+       static bool warned;
 
        rc = get_user(c, buffer);
        if (rc)
                return rc;
        if (c == '0' || c == 'n' || c == 'N')
                multiuser_mount = 0;
-       else if (c == '1' || c == 'y' || c == 'Y')
+       else if (c == '1' || c == 'y' || c == 'Y') {
                multiuser_mount = 1;
+               if (!warned) {
+                       warned = true;
+                       printk(KERN_WARNING "CIFS VFS: The legacy multiuser "
+                               "mount code is scheduled to be deprecated in "
+                               "3.5. Please switch to using the multiuser "
+                               "mount option.");
+               }
+       }
 
        return count;
 }