Blame view

fs/9p/fid.h 744 Bytes
1f3276132   Thomas Gleixner   treewide: Replace...
1
  /* SPDX-License-Identifier: GPL-2.0-only */
3ed8491c8   Eric Van Hensbergen   [PATCH] v9fs: deb...
2
3
4
5
  /*
   * V9FS FID Management
   *
   *  Copyright (C) 2005 by Eric Van Hensbergen <ericvh@gmail.com>
3ed8491c8   Eric Van Hensbergen   [PATCH] v9fs: deb...
6
   */
e0459f57b   Aneesh Kumar K.V   fs/9p: Prevent mu...
7
8
  #ifndef FS_9P_FID_H
  #define FS_9P_FID_H
3ed8491c8   Eric Van Hensbergen   [PATCH] v9fs: deb...
9
  #include <linux/list.h>
bd238fb43   Latchesar Ionkov   9p: Reorganizatio...
10
  struct p9_fid *v9fs_fid_lookup(struct dentry *dentry);
77d5a6b7d   Al Viro   9p: new helper - ...
11
12
13
14
  static inline struct p9_fid *v9fs_parent_fid(struct dentry *dentry)
  {
  	return v9fs_fid_lookup(dentry->d_parent);
  }
2ea03e1d6   Al Viro   9p: v9fs_fid_add(...
15
  void v9fs_fid_add(struct dentry *dentry, struct p9_fid *fid);
3cf387d78   Aneesh Kumar K.V   fs/9p: Add fid to...
16
  struct p9_fid *v9fs_writeback_fid(struct dentry *dentry);
797fc16d8   Al Viro   9p: fix braino in...
17
18
19
20
  static inline struct p9_fid *clone_fid(struct p9_fid *fid)
  {
  	return IS_ERR(fid) ? fid :  p9_client_walk(fid, 0, NULL, 1);
  }
7d50a29fe   Al Viro   9p: use clone_fid()
21
22
23
24
  static inline struct p9_fid *v9fs_fid_clone(struct dentry *dentry)
  {
  	return clone_fid(v9fs_fid_lookup(dentry));
  }
e0459f57b   Aneesh Kumar K.V   fs/9p: Prevent mu...
25
  #endif