Jan Blunck | c5e725f | 2008-02-14 19:34:31 -0800 | [diff] [blame] | 1 | #ifndef _LINUX_PATH_H |
| 2 | #define _LINUX_PATH_H |
| 3 | |
| 4 | struct dentry; |
| 5 | struct vfsmount; |
| 6 | |
| 7 | struct path { |
| 8 | struct vfsmount *mnt; |
| 9 | struct dentry *dentry; |
| 10 | }; |
| 11 | |
Jan Blunck | 5dd784d0 | 2008-02-14 19:34:38 -0800 | [diff] [blame] | 12 | extern void path_get(struct path *); |
Nick Piggin | b3e19d9 | 2011-01-07 17:50:11 +1100 | [diff] [blame] | 13 | extern void path_get_long(struct path *); |
Jan Blunck | 1d957f9 | 2008-02-14 19:34:35 -0800 | [diff] [blame] | 14 | extern void path_put(struct path *); |
Nick Piggin | b3e19d9 | 2011-01-07 17:50:11 +1100 | [diff] [blame] | 15 | extern void path_put_long(struct path *); |
Jan Blunck | 1d957f9 | 2008-02-14 19:34:35 -0800 | [diff] [blame] | 16 | |
Miklos Szeredi | 8df9d1a | 2010-08-10 11:41:41 +0200 | [diff] [blame] | 17 | static inline int path_equal(const struct path *path1, const struct path *path2) |
| 18 | { |
| 19 | return path1->mnt == path2->mnt && path1->dentry == path2->dentry; |
| 20 | } |
| 21 | |
Jan Blunck | c5e725f | 2008-02-14 19:34:31 -0800 | [diff] [blame] | 22 | #endif /* _LINUX_PATH_H */ |