aboutsummaryrefslogtreecommitdiffstats
path: root/fs/eventpoll.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/eventpoll.c')
-rw-r--r--fs/eventpoll.c19
1 files changed, 10 insertions, 9 deletions
diff --git a/fs/eventpoll.c b/fs/eventpoll.c
index 1b4491cdd115..08e7e6a555ca 100644
--- a/fs/eventpoll.c
+++ b/fs/eventpoll.c
@@ -268,9 +268,9 @@ static int ep_poll(struct eventpoll *ep, struct epoll_event __user *events,
268 int maxevents, long timeout); 268 int maxevents, long timeout);
269static int eventpollfs_delete_dentry(struct dentry *dentry); 269static int eventpollfs_delete_dentry(struct dentry *dentry);
270static struct inode *ep_eventpoll_inode(void); 270static struct inode *ep_eventpoll_inode(void);
271static struct super_block *eventpollfs_get_sb(struct file_system_type *fs_type, 271static int eventpollfs_get_sb(struct file_system_type *fs_type,
272 int flags, const char *dev_name, 272 int flags, const char *dev_name,
273 void *data); 273 void *data, struct vfsmount *mnt);
274 274
275/* 275/*
276 * This semaphore is used to serialize ep_free() and eventpoll_release_file(). 276 * This semaphore is used to serialize ep_free() and eventpoll_release_file().
@@ -337,20 +337,20 @@ static inline int ep_cmp_ffd(struct epoll_filefd *p1,
337/* Special initialization for the rb-tree node to detect linkage */ 337/* Special initialization for the rb-tree node to detect linkage */
338static inline void ep_rb_initnode(struct rb_node *n) 338static inline void ep_rb_initnode(struct rb_node *n)
339{ 339{
340 n->rb_parent = n; 340 rb_set_parent(n, n);
341} 341}
342 342
343/* Removes a node from the rb-tree and marks it for a fast is-linked check */ 343/* Removes a node from the rb-tree and marks it for a fast is-linked check */
344static inline void ep_rb_erase(struct rb_node *n, struct rb_root *r) 344static inline void ep_rb_erase(struct rb_node *n, struct rb_root *r)
345{ 345{
346 rb_erase(n, r); 346 rb_erase(n, r);
347 n->rb_parent = n; 347 rb_set_parent(n, n);
348} 348}
349 349
350/* Fast check to verify that the item is linked to the main rb-tree */ 350/* Fast check to verify that the item is linked to the main rb-tree */
351static inline int ep_rb_linked(struct rb_node *n) 351static inline int ep_rb_linked(struct rb_node *n)
352{ 352{
353 return n->rb_parent != n; 353 return rb_parent(n) != n;
354} 354}
355 355
356/* 356/*
@@ -1595,11 +1595,12 @@ eexit_1:
1595} 1595}
1596 1596
1597 1597
1598static struct super_block * 1598static int
1599eventpollfs_get_sb(struct file_system_type *fs_type, int flags, 1599eventpollfs_get_sb(struct file_system_type *fs_type, int flags,
1600 const char *dev_name, void *data) 1600 const char *dev_name, void *data, struct vfsmount *mnt)
1601{ 1601{
1602 return get_sb_pseudo(fs_type, "eventpoll:", NULL, EVENTPOLLFS_MAGIC); 1602 return get_sb_pseudo(fs_type, "eventpoll:", NULL, EVENTPOLLFS_MAGIC,
1603 mnt);
1603} 1604}
1604 1605
1605 1606