mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] Obscure possible bug in directory notify
@ 2000-11-08  6:40 Stephen Rothwell
  0 siblings, 0 replies; only message in thread
From: Stephen Rothwell @ 2000-11-08  6:40 UTC (permalink / raw)
  To: torvalds; +Cc: linux-kernel

Hi Linus,

This patch fixes a place where we could return with a read/write
lock held.  Also update MAINTAINERS and CREDITS files.

Cheers,
Stephen
-- 
Stephen Rothwell, Open Source Researcher, Linuxcare, Inc.
+61-2-62628990 tel, +61-2-62628991 fax 
sfr@linuxcare.com.au, http://www.linuxcare.com/ 
Linuxcare. Support for the revolution.

diff -ruN 2.4.0-test11pre1/CREDITS 2.4.0-test11pre1-not1/CREDITS
--- 2.4.0-test11pre1/CREDITS	Wed Nov  8 10:07:59 2000
+++ 2.4.0-test11pre1-not1/CREDITS	Wed Nov  8 17:09:20 2000
@@ -2240,11 +2240,12 @@
 S: Germany
 
 N: Stephen Rothwell
-E: sfr@linuxcare.com
+E: sfr@linuxcare.com.au
 W: http://linuxcare.com.au/sfr
 P: 1024/BD8C7805 CD A4 9D 01 10 6E 7E 3B  91 88 FA D9 C8 40 AA 02
 D: Boot/setup/build work for setup > 2K
 D: Author, APM driver
+D: Directory notification
 S: 66 Maltby Circuit
 S: Wanniassa ACT 2903
 S: Australia
diff -ruN 2.4.0-test11pre1/MAINTAINERS 2.4.0-test11pre1-not1/MAINTAINERS
--- 2.4.0-test11pre1/MAINTAINERS	Wed Nov  1 09:36:12 2000
+++ 2.4.0-test11pre1-not1/MAINTAINERS	Wed Nov  8 17:08:05 2000
@@ -353,6 +353,12 @@
 L:	digilnux@dgii.com
 S:	Maintained
 
+DIRECTORY NOTIFICATION
+P:	Stephen Rothwell
+M:	sfr@linuxcare.com.au
+L:	linux-kernel@vger.kernel.org
+S:	Supported
+
 DISK GEOMETRY AND PARTITION HANDLING
 P:     Andries Brouwer
 M:     aeb@veritas.com
diff -ruN 2.4.0-test11pre1/fs/dnotify.c 2.4.0-test11pre1-not1/fs/dnotify.c
--- 2.4.0-test11pre1/fs/dnotify.c	Wed Oct  4 10:37:09 2000
+++ 2.4.0-test11pre1-not1/fs/dnotify.c	Wed Nov  8 17:06:08 2000
@@ -103,14 +103,14 @@
 	write_lock(&dn_lock);
 	prev = &inode->i_dnotify;
 	while ((dn = *prev) != NULL) {
-		if ((dn->dn_mask & event) == 0) {
-			prev = &dn->dn_next;
-			continue;
-		}
 		if (dn->dn_magic != DNOTIFY_MAGIC) {
 		        printk(KERN_ERR "__inode_dir_notify: bad magic "
 				"number in dnotify_struct!\n");
-		        return;
+		        goto out;
+		}
+		if ((dn->dn_mask & event) == 0) {
+			prev = &dn->dn_next;
+			continue;
 		}
 		fown = &dn->dn_filp->f_owner;
 		if (fown->pid)
@@ -125,6 +125,7 @@
 	}
 	if (changed)
 		redo_inode_mask(inode);
+out:
 	write_unlock(&dn_lock);
 }
 
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2000-11-08  6:41 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-11-08  6:40 [PATCH] Obscure possible bug in directory notify Stephen Rothwell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®