Lines Matching refs:sbi
69 struct autofs_sb_info *sbi = autofs_sbi(dentry->d_sb); in autofs_del_active() local
73 spin_lock(&sbi->lookup_lock); in autofs_del_active()
75 spin_unlock(&sbi->lookup_lock); in autofs_del_active()
81 struct autofs_sb_info *sbi = autofs_sbi(dentry->d_sb); in autofs_dir_open() local
86 if (autofs_oz_mode(sbi)) in autofs_dir_open()
98 spin_lock(&sbi->lookup_lock); in autofs_dir_open()
100 spin_unlock(&sbi->lookup_lock); in autofs_dir_open()
103 spin_unlock(&sbi->lookup_lock); in autofs_dir_open()
112 struct autofs_sb_info *sbi = autofs_sbi(de->d_sb); in autofs_dentry_release() local
119 if (sbi) { in autofs_dentry_release()
120 spin_lock(&sbi->lookup_lock); in autofs_dentry_release()
125 spin_unlock(&sbi->lookup_lock); in autofs_dentry_release()
133 struct autofs_sb_info *sbi = autofs_sbi(dentry->d_sb); in autofs_lookup_active() local
141 head = &sbi->active_list; in autofs_lookup_active()
144 spin_lock(&sbi->lookup_lock); in autofs_lookup_active()
174 spin_unlock(&sbi->lookup_lock); in autofs_lookup_active()
180 spin_unlock(&sbi->lookup_lock); in autofs_lookup_active()
188 struct autofs_sb_info *sbi = autofs_sbi(dentry->d_sb); in autofs_lookup_expiring() local
196 head = &sbi->expiring_list; in autofs_lookup_expiring()
199 spin_lock(&sbi->lookup_lock); in autofs_lookup_expiring()
206 spin_unlock(&sbi->lookup_lock); in autofs_lookup_expiring()
234 spin_unlock(&sbi->lookup_lock); in autofs_lookup_expiring()
240 spin_unlock(&sbi->lookup_lock); in autofs_lookup_expiring()
247 struct autofs_sb_info *sbi = autofs_sbi(path->dentry->d_sb); in autofs_mount_wait() local
255 status = autofs_wait(sbi, path, NFY_MOUNT); in autofs_mount_wait()
260 if (!(sbi->flags & AUTOFS_SBI_STRICTEXPIRE)) in autofs_mount_wait()
292 struct autofs_sb_info *sbi = autofs_sbi(dentry->d_sb); in autofs_mountpoint_changed() local
315 if (autofs_type_indirect(sbi->type) && d_unhashed(dentry)) { in autofs_mountpoint_changed()
334 struct autofs_sb_info *sbi = autofs_sbi(dentry->d_sb); in autofs_d_automount() local
341 if (autofs_oz_mode(sbi)) in autofs_d_automount()
357 spin_lock(&sbi->fs_lock); in autofs_d_automount()
359 spin_unlock(&sbi->fs_lock); in autofs_d_automount()
372 spin_unlock(&sbi->fs_lock); in autofs_d_automount()
388 if (sbi->version > 4) { in autofs_d_automount()
390 spin_unlock(&sbi->fs_lock); in autofs_d_automount()
395 spin_unlock(&sbi->fs_lock); in autofs_d_automount()
400 spin_unlock(&sbi->fs_lock); in autofs_d_automount()
402 spin_lock(&sbi->fs_lock); in autofs_d_automount()
405 spin_unlock(&sbi->fs_lock); in autofs_d_automount()
409 spin_unlock(&sbi->fs_lock); in autofs_d_automount()
422 struct autofs_sb_info *sbi = autofs_sbi(dentry->d_sb); in autofs_d_manage() local
429 if (autofs_oz_mode(sbi)) { in autofs_d_manage()
468 spin_lock(&sbi->fs_lock); in autofs_d_manage()
487 spin_unlock(&sbi->fs_lock); in autofs_d_manage()
496 struct autofs_sb_info *sbi; in autofs_lookup() local
506 sbi = autofs_sbi(dir->i_sb); in autofs_lookup()
510 sbi->flags & AUTOFS_SBI_CATATONIC, in autofs_lookup()
511 autofs_oz_mode(sbi)); in autofs_lookup()
523 if (!autofs_oz_mode(sbi) && !IS_ROOT(dentry->d_parent)) in autofs_lookup()
526 ino = autofs_new_ino(sbi); in autofs_lookup()
530 spin_lock(&sbi->lookup_lock); in autofs_lookup()
534 autofs_type_indirect(sbi->type)) in autofs_lookup()
539 list_add(&ino->active, &sbi->active_list); in autofs_lookup()
540 spin_unlock(&sbi->lookup_lock); in autofs_lookup()
550 struct autofs_sb_info *sbi = autofs_sbi(inode->i_sb); in autofs_dir_permission() local
552 if (!autofs_oz_mode(sbi)) in autofs_dir_permission()
559 if (sbi->flags & AUTOFS_SBI_CATATONIC) in autofs_dir_permission()
625 struct autofs_sb_info *sbi = autofs_sbi(dir->i_sb); in autofs_dir_unlink() local
638 spin_lock(&sbi->lookup_lock); in autofs_dir_unlink()
641 spin_unlock(&sbi->lookup_lock); in autofs_dir_unlink()
694 struct autofs_sb_info *sbi = autofs_sbi(dir->i_sb); in autofs_dir_rmdir() local
703 spin_lock(&sbi->lookup_lock); in autofs_dir_rmdir()
706 spin_unlock(&sbi->lookup_lock); in autofs_dir_rmdir()
708 if (sbi->version < 5) in autofs_dir_rmdir()
727 struct autofs_sb_info *sbi = autofs_sbi(dir->i_sb); in autofs_dir_mkdir() local
745 if (sbi->version < 5) in autofs_dir_mkdir()
759 static inline int autofs_compat_get_set_timeout(struct autofs_sb_info *sbi, in autofs_compat_get_set_timeout() argument
769 rv = put_user(sbi->exp_timeout/HZ, p); in autofs_compat_get_set_timeout()
774 sbi->exp_timeout = 0; in autofs_compat_get_set_timeout()
776 sbi->exp_timeout = ntimeout * HZ; in autofs_compat_get_set_timeout()
784 static inline int autofs_get_set_timeout(struct autofs_sb_info *sbi, in autofs_get_set_timeout() argument
794 rv = put_user(sbi->exp_timeout/HZ, p); in autofs_get_set_timeout()
799 sbi->exp_timeout = 0; in autofs_get_set_timeout()
801 sbi->exp_timeout = ntimeout * HZ; in autofs_get_set_timeout()
809 static inline int autofs_get_protover(struct autofs_sb_info *sbi, in autofs_get_protover() argument
812 return put_user(sbi->version, p); in autofs_get_protover()
816 static inline int autofs_get_protosubver(struct autofs_sb_info *sbi, in autofs_get_protosubver() argument
819 return put_user(sbi->sub_version, p); in autofs_get_protosubver()
857 struct autofs_sb_info *sbi = autofs_sbi(inode->i_sb); in autofs_root_ioctl_unlocked() local
861 cmd, arg, sbi, task_pgrp_nr(current)); in autofs_root_ioctl_unlocked()
867 if (!autofs_oz_mode(sbi) && !capable(CAP_SYS_ADMIN)) in autofs_root_ioctl_unlocked()
872 return autofs_wait_release(sbi, (autofs_wqt_t) arg, 0); in autofs_root_ioctl_unlocked()
874 return autofs_wait_release(sbi, (autofs_wqt_t) arg, -ENOENT); in autofs_root_ioctl_unlocked()
876 autofs_catatonic_mode(sbi); in autofs_root_ioctl_unlocked()
879 return autofs_get_protover(sbi, p); in autofs_root_ioctl_unlocked()
881 return autofs_get_protosubver(sbi, p); in autofs_root_ioctl_unlocked()
883 return autofs_get_set_timeout(sbi, p); in autofs_root_ioctl_unlocked()
886 return autofs_compat_get_set_timeout(sbi, p); in autofs_root_ioctl_unlocked()
894 return autofs_expire_run(inode->i_sb, filp->f_path.mnt, sbi, p); in autofs_root_ioctl_unlocked()
898 filp->f_path.mnt, sbi, p); in autofs_root_ioctl_unlocked()