patch-2.4.0-test9 linux/include/linux/dnotify.h

Next file: linux/include/linux/elf.h
Previous file: linux/include/linux/devpts_fs.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.0-test8/linux/include/linux/dnotify.h linux/include/linux/dnotify.h
@@ -0,0 +1,25 @@
+/*
+ * Directory notification for Linux
+ *
+ * Copyright 2000 (C) Stephen Rothwell
+ */
+
+struct dnotify_struct {
+	struct dnotify_struct *	dn_next;
+	int			dn_magic;
+	unsigned long		dn_mask;	/* Events to be notified
+						   see linux/fcntl.h */
+	int			dn_fd;
+	struct file *		dn_filp;
+};
+
+#define DNOTIFY_MAGIC	0x444E4F54
+
+extern void __inode_dir_notify(struct inode *, unsigned long);
+extern int fcntl_dirnotify(int, struct file *, unsigned long);
+
+static inline void inode_dir_notify(struct inode *inode, unsigned long event)
+{
+	if ((inode)->i_dnotify_mask & (event))
+		__inode_dir_notify(inode, event);
+}

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)