Lines Matching full:who
42 static int thaw_super_locked(struct super_block *sb, enum freeze_holder who);
1963 static inline int freeze_inc(struct super_block *sb, enum freeze_holder who) in freeze_inc() argument
1965 WARN_ON_ONCE((who & ~FREEZE_FLAGS)); in freeze_inc()
1966 WARN_ON_ONCE(hweight32(who & FREEZE_HOLDERS) > 1); in freeze_inc()
1968 if (who & FREEZE_HOLDER_KERNEL) in freeze_inc()
1970 if (who & FREEZE_HOLDER_USERSPACE) in freeze_inc()
1975 static inline int freeze_dec(struct super_block *sb, enum freeze_holder who) in freeze_dec() argument
1977 WARN_ON_ONCE((who & ~FREEZE_FLAGS)); in freeze_dec()
1978 WARN_ON_ONCE(hweight32(who & FREEZE_HOLDERS) > 1); in freeze_dec()
1980 if ((who & FREEZE_HOLDER_KERNEL) && sb->s_writers.freeze_kcount) in freeze_dec()
1982 if ((who & FREEZE_HOLDER_USERSPACE) && sb->s_writers.freeze_ucount) in freeze_dec()
1987 static inline bool may_freeze(struct super_block *sb, enum freeze_holder who) in may_freeze() argument
1989 WARN_ON_ONCE((who & ~FREEZE_FLAGS)); in may_freeze()
1990 WARN_ON_ONCE(hweight32(who & FREEZE_HOLDERS) > 1); in may_freeze()
1992 if (who & FREEZE_HOLDER_KERNEL) in may_freeze()
1993 return (who & FREEZE_MAY_NEST) || in may_freeze()
1995 if (who & FREEZE_HOLDER_USERSPACE) in may_freeze()
1996 return (who & FREEZE_MAY_NEST) || in may_freeze()
2004 * @who: context that wants to freeze
2010 * @who should be:
2015 * The @who argument distinguishes between the kernel and userspace trying to
2056 int freeze_super(struct super_block *sb, enum freeze_holder who) in freeze_super() argument
2068 if (may_freeze(sb, who)) in freeze_super()
2069 ret = !!WARN_ON_ONCE(freeze_inc(sb, who) == 1); in freeze_super()
2089 WARN_ON_ONCE(freeze_inc(sb, who) > 1); in freeze_super()
2136 WARN_ON_ONCE(freeze_inc(sb, who) > 1); in freeze_super()
2151 static int thaw_super_locked(struct super_block *sb, enum freeze_holder who) in thaw_super_locked() argument
2162 if (freeze_dec(sb, who)) in thaw_super_locked()
2177 freeze_inc(sb, who); in thaw_super_locked()
2198 * @who: context that wants to freeze
2203 * @who should be:
2212 int thaw_super(struct super_block *sb, enum freeze_holder who) in thaw_super() argument
2218 return thaw_super_locked(sb, who); in thaw_super()