Lines Matching defs:mutex
43 static inline struct mutex *kernfs_open_file_mutex_ptr(struct kernfs_node *kn)
50 static inline struct mutex *kernfs_open_file_mutex_lock(struct kernfs_node *kn)
52 struct mutex *lock;
82 * the caller guarantees that this mutex is being held, other updaters can't
151 * @of->mutex nests outside active ref and is primarily to ensure that
154 mutex_lock(&of->mutex);
196 mutex_unlock(&of->mutex);
237 * @of->mutex nests outside active ref and is used both to ensure that
240 mutex_lock(&of->mutex);
243 mutex_unlock(&of->mutex);
256 mutex_unlock(&of->mutex);
322 * @of->mutex nests outside active ref and is used both to ensure that
325 mutex_lock(&of->mutex);
327 mutex_unlock(&of->mutex);
339 mutex_unlock(&of->mutex);
495 * mmap path and of->mutex are prone to triggering spurious lockdep
498 * without grabbing @of->mutex by testing HAS_MMAP flag. See the
504 mutex_lock(&of->mutex);
542 mutex_unlock(&of->mutex);
565 struct mutex *mutex;
567 mutex = kernfs_open_file_mutex_lock(kn);
574 mutex_unlock(mutex);
587 mutex_unlock(mutex);
610 struct mutex *mutex;
612 mutex = kernfs_open_file_mutex_lock(kn);
616 mutex_unlock(mutex);
636 mutex_unlock(mutex);
676 * @of->mutex for files which implement mmap. This is a rather
678 * mm->mmap_lock - mmap nests @of->mutex under mm->mmap_lock and
680 * which mm->mmap_lock nests, while holding @of->mutex. As each
681 * open file has a separate mutex, it's okay as long as those don't
687 * look that way and give @of->mutex different static lockdep keys.
690 mutex_init(&of->mutex);
692 mutex_init(&of->mutex);
745 /* nobody has access to @of yet, skip @of->mutex */
774 * @kernfs_open_file_mutex_ptr(kn) is enough. @of->mutex can't be used
798 struct mutex *mutex;
800 mutex = kernfs_open_file_mutex_lock(kn);
802 mutex_unlock(mutex);
836 struct mutex *mutex;
838 mutex = kernfs_open_file_mutex_lock(kn);
841 mutex_unlock(mutex);
859 mutex_unlock(mutex);