Lines Matching refs:dn
35 struct dnotify_struct *dn; member
49 struct dnotify_struct *dn; in dnotify_recalc_inode_mask() local
56 for (dn = dn_mark->dn; dn != NULL; dn = dn->dn_next) in dnotify_recalc_inode_mask()
57 new_mask |= (dn->dn_mask & ~FS_DN_MULTISHOT); in dnotify_recalc_inode_mask()
78 struct dnotify_struct *dn; in dnotify_handle_event() local
90 prev = &dn_mark->dn; in dnotify_handle_event()
91 while ((dn = *prev) != NULL) { in dnotify_handle_event()
92 if ((dn->dn_mask & test_mask) == 0) { in dnotify_handle_event()
93 prev = &dn->dn_next; in dnotify_handle_event()
96 fown = &dn->dn_filp->f_owner; in dnotify_handle_event()
97 send_sigio(fown, dn->dn_fd, POLL_MSG); in dnotify_handle_event()
98 if (dn->dn_mask & FS_DN_MULTISHOT) in dnotify_handle_event()
99 prev = &dn->dn_next; in dnotify_handle_event()
101 *prev = dn->dn_next; in dnotify_handle_event()
102 kmem_cache_free(dnotify_struct_cache, dn); in dnotify_handle_event()
118 BUG_ON(dn_mark->dn); in dnotify_free_mark()
139 struct dnotify_struct *dn; in dnotify_flush() local
156 prev = &dn_mark->dn; in dnotify_flush()
157 while ((dn = *prev) != NULL) { in dnotify_flush()
158 if ((dn->dn_owner == id) && (dn->dn_filp == filp)) { in dnotify_flush()
159 *prev = dn->dn_next; in dnotify_flush()
160 kmem_cache_free(dnotify_struct_cache, dn); in dnotify_flush()
164 prev = &dn->dn_next; in dnotify_flush()
171 if (dn_mark->dn == NULL) { in dnotify_flush()
212 static int attach_dn(struct dnotify_struct *dn, struct dnotify_mark *dn_mark, in attach_dn() argument
217 odn = dn_mark->dn; in attach_dn()
228 dn->dn_mask = mask; in attach_dn()
229 dn->dn_fd = fd; in attach_dn()
230 dn->dn_filp = filp; in attach_dn()
231 dn->dn_owner = id; in attach_dn()
232 dn->dn_next = dn_mark->dn; in attach_dn()
233 dn_mark->dn = dn; in attach_dn()
247 struct dnotify_struct *dn; in fcntl_dirnotify() local
256 dn = NULL; in fcntl_dirnotify()
289 dn = kmem_cache_alloc(dnotify_struct_cache, GFP_KERNEL); in fcntl_dirnotify()
290 if (!dn) { in fcntl_dirnotify()
306 new_dn_mark->dn = NULL; in fcntl_dirnotify()
353 error = attach_dn(dn, dn_mark, id, fd, filp, mask); in fcntl_dirnotify()
356 dn = NULL; in fcntl_dirnotify()
375 if (dn) in fcntl_dirnotify()
376 kmem_cache_free(dnotify_struct_cache, dn); in fcntl_dirnotify()