Lines Matching refs:cifs_sb
192 struct cifs_sb_info *cifs_sb; in cifs_read_super() local
197 cifs_sb = CIFS_SB(sb); in cifs_read_super()
198 tcon = cifs_sb_master_tcon(cifs_sb); in cifs_read_super()
200 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_POSIXACL) in cifs_read_super()
247 if (cifs_sb->ctx->rsize == 0) in cifs_read_super()
248 cifs_sb->ctx->rsize = in cifs_read_super()
249 tcon->ses->server->ops->negotiate_rsize(tcon, cifs_sb->ctx); in cifs_read_super()
250 if (cifs_sb->ctx->rasize) in cifs_read_super()
251 sb->s_bdi->ra_pages = cifs_sb->ctx->rasize / PAGE_SIZE; in cifs_read_super()
253 sb->s_bdi->ra_pages = 2 * (cifs_sb->ctx->rsize / PAGE_SIZE); in cifs_read_super()
276 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_SERVER_INUM) { in cifs_read_super()
291 struct cifs_sb_info *cifs_sb = CIFS_SB(sb); in cifs_kill_sb() local
297 if (cifs_sb->root) { in cifs_kill_sb()
298 close_all_cached_dirs(cifs_sb); in cifs_kill_sb()
301 dput(cifs_sb->root); in cifs_kill_sb()
302 cifs_sb->root = NULL; in cifs_kill_sb()
306 cifs_umount(cifs_sb); in cifs_kill_sb()
313 struct cifs_sb_info *cifs_sb = CIFS_SB(sb); in cifs_statfs() local
314 struct cifs_tcon *tcon = cifs_sb_master_tcon(cifs_sb); in cifs_statfs()
335 rc = server->ops->queryfs(xid, tcon, cifs_sb, buf); in cifs_statfs()
343 struct cifs_sb_info *cifs_sb = CIFS_FILE_SB(file); in cifs_fallocate() local
344 struct cifs_tcon *tcon = cifs_sb_master_tcon(cifs_sb); in cifs_fallocate()
356 struct cifs_sb_info *cifs_sb; in cifs_permission() local
358 cifs_sb = CIFS_SB(inode->i_sb); in cifs_permission()
360 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_PERM) { in cifs_permission()
498 cifs_show_cache_flavor(struct seq_file *s, struct cifs_sb_info *cifs_sb) in cifs_show_cache_flavor() argument
502 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_STRICT_IO) in cifs_show_cache_flavor()
504 else if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_DIRECT_IO) in cifs_show_cache_flavor()
506 else if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_RW_CACHE) in cifs_show_cache_flavor()
508 else if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_RO_CACHE) in cifs_show_cache_flavor()
520 struct cifs_sb_info *cifs_sb = CIFS_SB(root->d_sb); in cifs_show_devname() local
521 char *devname = kstrdup(cifs_sb->ctx->source, GFP_KERNEL); in cifs_show_devname()
542 struct cifs_sb_info *cifs_sb = CIFS_SB(root->d_sb); in cifs_show_options() local
543 struct cifs_tcon *tcon = cifs_sb_master_tcon(cifs_sb); in cifs_show_options()
549 cifs_show_cache_flavor(s, cifs_sb); in cifs_show_options()
553 if (cifs_sb->ctx->multiuser) in cifs_show_options()
578 from_kuid_munged(&init_user_ns, cifs_sb->ctx->linux_uid)); in cifs_show_options()
579 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_OVERR_UID) in cifs_show_options()
585 from_kgid_munged(&init_user_ns, cifs_sb->ctx->linux_gid)); in cifs_show_options()
586 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_OVERR_GID) in cifs_show_options()
595 cifs_sb->ctx->file_mode, in cifs_show_options()
596 cifs_sb->ctx->dir_mode); in cifs_show_options()
597 if (cifs_sb->ctx->iocharset) in cifs_show_options()
598 seq_printf(s, ",iocharset=%s", cifs_sb->ctx->iocharset); in cifs_show_options()
607 if (cifs_sb->ctx->no_sparse) in cifs_show_options()
625 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_DFS) in cifs_show_options()
627 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_POSIX_PATHS) in cifs_show_options()
629 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_SET_UID) in cifs_show_options()
631 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_UID_FROM_ACL) in cifs_show_options()
633 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_SERVER_INUM) in cifs_show_options()
635 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_RWPIDFORWARD) in cifs_show_options()
637 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NOPOSIXBRL) in cifs_show_options()
639 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_XATTR) in cifs_show_options()
641 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_MAP_SPECIAL_CHR) in cifs_show_options()
643 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_MAP_SFM_CHR) in cifs_show_options()
645 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_UNX_EMUL) in cifs_show_options()
647 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_BRL) in cifs_show_options()
649 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_HANDLE_CACHE) in cifs_show_options()
651 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_MODE_FROM_SID) in cifs_show_options()
653 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_CIFS_ACL) in cifs_show_options()
655 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_DYNPERM) in cifs_show_options()
659 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_MF_SYMLINKS) in cifs_show_options()
661 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_FSCACHE) in cifs_show_options()
663 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NOSSYNC) in cifs_show_options()
665 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_PERM) in cifs_show_options()
667 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_CIFS_BACKUPUID) in cifs_show_options()
670 cifs_sb->ctx->backupuid)); in cifs_show_options()
671 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_CIFS_BACKUPGID) in cifs_show_options()
674 cifs_sb->ctx->backupgid)); in cifs_show_options()
676 seq_printf(s, ",rsize=%u", cifs_sb->ctx->rsize); in cifs_show_options()
677 seq_printf(s, ",wsize=%u", cifs_sb->ctx->wsize); in cifs_show_options()
678 seq_printf(s, ",bsize=%u", cifs_sb->ctx->bsize); in cifs_show_options()
679 if (cifs_sb->ctx->rasize) in cifs_show_options()
680 seq_printf(s, ",rasize=%u", cifs_sb->ctx->rasize); in cifs_show_options()
710 if (cifs_sb->ctx->acdirmax == cifs_sb->ctx->acregmax) in cifs_show_options()
711 seq_printf(s, ",actimeo=%lu", cifs_sb->ctx->acregmax / HZ); in cifs_show_options()
713 seq_printf(s, ",acdirmax=%lu", cifs_sb->ctx->acdirmax / HZ); in cifs_show_options()
714 seq_printf(s, ",acregmax=%lu", cifs_sb->ctx->acregmax / HZ); in cifs_show_options()
716 seq_printf(s, ",closetimeo=%lu", cifs_sb->ctx->closetimeo / HZ); in cifs_show_options()
730 struct cifs_sb_info *cifs_sb = CIFS_SB(sb); in cifs_umount_begin() local
733 if (cifs_sb == NULL) in cifs_umount_begin()
736 tcon = cifs_sb_master_tcon(cifs_sb); in cifs_umount_begin()
773 struct cifs_sb_info *cifs_sb = CIFS_SB(sb); in cifs_freeze() local
776 if (cifs_sb == NULL) in cifs_freeze()
779 tcon = cifs_sb_master_tcon(cifs_sb); in cifs_freeze()
801 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); in cifs_drop_inode() local
804 return !(cifs_sb->mnt_cifs_flags & CIFS_MOUNT_SERVER_INUM) || in cifs_drop_inode()
837 struct cifs_sb_info *cifs_sb = CIFS_SB(sb); in cifs_get_root() local
842 if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_USE_PREFIX_PATH) in cifs_get_root()
845 full_path = cifs_build_path_to_root(ctx, cifs_sb, in cifs_get_root()
846 cifs_sb_master_tcon(cifs_sb), 0); in cifs_get_root()
852 sep = CIFS_DIR_SEP(cifs_sb); in cifs_get_root()
887 sb->s_fs_info = mnt_data->cifs_sb; in cifs_set_super()
896 struct cifs_sb_info *cifs_sb; in cifs_smb3_do_mount() local
908 cifs_sb = kzalloc(sizeof(*cifs_sb), GFP_KERNEL); in cifs_smb3_do_mount()
909 if (!cifs_sb) in cifs_smb3_do_mount()
912 cifs_sb->ctx = kzalloc(sizeof(struct smb3_fs_context), GFP_KERNEL); in cifs_smb3_do_mount()
913 if (!cifs_sb->ctx) { in cifs_smb3_do_mount()
917 rc = smb3_fs_context_dup(cifs_sb->ctx, old_ctx); in cifs_smb3_do_mount()
923 rc = cifs_setup_cifs_sb(cifs_sb); in cifs_smb3_do_mount()
929 rc = cifs_mount(cifs_sb, cifs_sb->ctx); in cifs_smb3_do_mount()
938 mnt_data.ctx = cifs_sb->ctx; in cifs_smb3_do_mount()
939 mnt_data.cifs_sb = cifs_sb; in cifs_smb3_do_mount()
947 cifs_umount(cifs_sb); in cifs_smb3_do_mount()
953 cifs_umount(cifs_sb); in cifs_smb3_do_mount()
954 cifs_sb = NULL; in cifs_smb3_do_mount()
965 root = cifs_get_root(cifs_sb ? cifs_sb->ctx : old_ctx, sb); in cifs_smb3_do_mount()
969 if (cifs_sb) in cifs_smb3_do_mount()
970 cifs_sb->root = dget(root); in cifs_smb3_do_mount()
979 kfree(cifs_sb->prepath); in cifs_smb3_do_mount()
980 smb3_cleanup_fs_context(cifs_sb->ctx); in cifs_smb3_do_mount()
981 kfree(cifs_sb); in cifs_smb3_do_mount()