[kernel] r11292 - in dists/etch/linux-2.6/debian: . patches/bugfix patches/series

Dann Frazier dannf at alioth.debian.org
Mon May 5 16:35:34 UTC 2008


Author: dannf
Date: Mon May  5 16:35:32 2008
New Revision: 11292

Log:
* Add missing locking for the dnotify-race fix that was included in
  the upstream commit

Added:
   dists/etch/linux-2.6/debian/patches/bugfix/dnotify-race-locking.patch
Modified:
   dists/etch/linux-2.6/debian/changelog
   dists/etch/linux-2.6/debian/patches/series/21

Modified: dists/etch/linux-2.6/debian/changelog
==============================================================================
--- dists/etch/linux-2.6/debian/changelog	(original)
+++ dists/etch/linux-2.6/debian/changelog	Mon May  5 16:35:32 2008
@@ -3,8 +3,10 @@
   * 3w-xxxx: Fix data corruption on em64t systems w/ > 2GB of memory
     (closes: #464923).
   * Merge in changes from 2.6.18.dfsg.1-18etch[2,3]
+  * Add missing locking for the dnotify-race fix that was included in
+    the upstream commit
 
- -- dann frazier <dannf at debian.org>  Thu, 01 May 2008 13:59:17 -0600
+ -- dann frazier <dannf at debian.org>  Fri, 02 May 2008 18:38:42 -0600
 
 linux-2.6 (2.6.18.dfsg.1-20) stable; urgency=high
 

Added: dists/etch/linux-2.6/debian/patches/bugfix/dnotify-race-locking.patch
==============================================================================
--- (empty file)
+++ dists/etch/linux-2.6/debian/patches/bugfix/dnotify-race-locking.patch	Mon May  5 16:35:32 2008
@@ -0,0 +1,28 @@
+diff -urpN linux-source-2.6.18.orig/fs/dnotify.c linux-source-2.6.18/fs/dnotify.c
+--- linux-source-2.6.18.orig/fs/dnotify.c	2008-04-23 21:53:08.000000000 -0600
++++ linux-source-2.6.18/fs/dnotify.c	2008-05-02 18:33:30.000000000 -0600
+@@ -69,6 +69,9 @@ int fcntl_dirnotify(int fd, struct file 
+ 	struct dnotify_struct **prev;
+ 	struct inode *inode;
+ 	fl_owner_t id = current->files;
++#ifndef __GENKSYMS__
++	struct file *f;
++#endif
+ 	int error = 0;
+ 
+ 	if ((arg & ~DN_MULTISHOT) == 0) {
+@@ -96,8 +99,13 @@ int fcntl_dirnotify(int fd, struct file 
+ 	}
+ 
+ #ifndef __GENKSYMS__
++	rcu_read_lock();
++	f = fcheck(fd);
++	rcu_read_unlock();
+ 	/* we'd lost the race with close(), sod off silently */
+-	if (fcheck(fd) != filp)
++	/* note that inode->i_lock prevents reordering problems
++	 * between accesses to descriptor table and ->i_dnotify */
++	if (f != filp)
+ 		goto out_free;
+ #endif
+ 

Modified: dists/etch/linux-2.6/debian/patches/series/21
==============================================================================
--- dists/etch/linux-2.6/debian/patches/series/21	(original)
+++ dists/etch/linux-2.6/debian/patches/series/21	Mon May  5 16:35:32 2008
@@ -1 +1,2 @@
 + bugfix/3w-xxxx-bigmem-corruption.patch
++ bugfix/dnotify-race-locking.patch



More information about the Kernel-svn-changes mailing list