Commit 2b280fab12b6697b6a7a24a13aaf9f4339edd075

Authored by Steve French
1 parent a1fe78f16e

[CIFS] add more complete mount options to cifs_show_options

adds various options to cifs_show_options
(displayed when you cat /proc/mounts with a cifs mount).  I limited
the new ones to values that are associated with the mount with the
exception of "seal" (which is a per tree connection property, but I
thought was important enough to show through).

Eventually cifs's parse_mount_options also needs to
be rewritten to use the match_token API but that would be a big enough
change that I would prefer that changing parse_mount_options wait
until next release.

Signed-off-by: Steve French <sfrench@us.ibm.com>

Showing 1 changed file with 30 additions and 1 deletions Side-by-side Diff

1 1 /*
2 2 * fs/cifs/cifsfs.c
3 3 *
4   - * Copyright (C) International Business Machines Corp., 2002,2007
  4 + * Copyright (C) International Business Machines Corp., 2002,2008
5 5 * Author(s): Steve French (sfrench@us.ibm.com)
6 6 *
7 7 * Common Internet FileSystem (CIFS) client
8 8  
... ... @@ -353,9 +353,38 @@
353 353 if ((cifs_sb->mnt_cifs_flags & CIFS_MOUNT_OVERR_GID) ||
354 354 !(cifs_sb->tcon->unix_ext))
355 355 seq_printf(s, ",gid=%d", cifs_sb->mnt_gid);
  356 + if (!cifs_sb->tcon->unix_ext) {
  357 + seq_printf(s, ",file_mode=0%o,dir_mode=0%o",
  358 + cifs_sb->mnt_file_mode,
  359 + cifs_sb->mnt_dir_mode);
  360 + }
  361 + if (cifs_sb->tcon->seal)
  362 + seq_printf(s, ",seal");
  363 + seq_printf(s, ",nocase");
356 364 }
357 365 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_POSIX_PATHS)
358 366 seq_printf(s, ",posixpaths");
  367 + if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_SET_UID)
  368 + seq_printf(s, ",setuids");
  369 + if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_SERVER_INUM)
  370 + seq_printf(s, ",serverino");
  371 + if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_DIRECT_IO)
  372 + seq_printf(s, ",directio");
  373 + if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_XATTR)
  374 + seq_printf(s, ",nouser_xattr");
  375 + if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_MAP_SPECIAL_CHR)
  376 + seq_printf(s, ",mapchars");
  377 + if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_UNX_EMUL)
  378 + seq_printf(s, ",sfu");
  379 + if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_BRL)
  380 + seq_printf(s, ",nobrl");
  381 + if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_CIFS_ACL)
  382 + seq_printf(s, ",cifsacl");
  383 + if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_DYNPERM)
  384 + seq_printf(s, ",dynperm");
  385 + if (m->mnt_sb->s_flags & MS_POSIXACL)
  386 + seq_printf(s, ",acl");
  387 +
359 388 seq_printf(s, ",rsize=%d", cifs_sb->rsize);
360 389 seq_printf(s, ",wsize=%d", cifs_sb->wsize);
361 390 }