From: Steve French Date: Sat, 12 Sep 2015 00:24:19 +0000 (-0500) Subject: [CIFS] mount option sec=none not displayed properly in /proc/mounts X-Git-Tag: firefly_0821_release~176^2~1061^2 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=eda2116f4ab6d79cfcffc202b5d2bbb0797ba013;p=firefly-linux-kernel-4.4.55.git [CIFS] mount option sec=none not displayed properly in /proc/mounts When the user specifies "sec=none" in a cifs mount, we set sec_type as unspecified (and set a flag and the username will be null) rather than setting sectype as "none" so cifs_show_security was not properly displaying it in cifs /proc/mounts entries. Signed-off-by: Steve French Reviewed-by: Jeff Layton --- diff --git a/fs/cifs/cifsfs.c b/fs/cifs/cifsfs.c index 6a1119e87fbb..e739950ca084 100644 --- a/fs/cifs/cifsfs.c +++ b/fs/cifs/cifsfs.c @@ -325,8 +325,11 @@ cifs_show_address(struct seq_file *s, struct TCP_Server_Info *server) static void cifs_show_security(struct seq_file *s, struct cifs_ses *ses) { - if (ses->sectype == Unspecified) + if (ses->sectype == Unspecified) { + if (ses->user_name == NULL) + seq_puts(s, ",sec=none"); return; + } seq_puts(s, ",sec=");