cifs: handle "sloppy" option appropriately
authorJeff Layton <jlayton@redhat.com>
Fri, 23 Mar 2012 18:40:56 +0000 (14:40 -0400)
committerJeff Layton <jlayton@redhat.com>
Fri, 23 Mar 2012 18:40:56 +0000 (14:40 -0400)
commitd81625587f4fac44a4367c468ba2fe2d981460f8
tree62b20ee4d39c345b7348a8a8fdad946dfde73919
parent8830d7e07a5e38bc47650a7554b7c1cfd49902bf
cifs: handle "sloppy" option appropriately

cifs.ko has historically been tolerant of options that it does not
recognize. This is not normal behavior for a filesystem however.
Usually, it should only do this if you mount with '-s', and autofs
generally passes -s to the mount command to allow this behavior.

This patch makes cifs handle the option "sloppy" appropriately. If it's
present in the options string, then the client will tolerate options
that it doesn't recognize. If it's not present then the client will
error out in the presence of options that it does not recognize and
throw an error message explaining why.

There is also a companion patch being proposed for mount.cifs to make it
append "sloppy" to the mount options when passed the '-s' flag. This also
should (obviously) be applied on top of Sachin's conversion to the
standard option parser.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
Acked-By: Sachin Prabhu <sprabhu@redhat.com>
fs/cifs/connect.c