]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
Add unregister_chrdev_region-semaphore-fix.patch from Wen-chien Jesse Sung
authorChris Wright <chrisw@osdl.org>
Thu, 30 Jun 2005 21:34:34 +0000 (14:34 -0700)
committerChris Wright <chrisw@osdl.org>
Thu, 30 Jun 2005 21:34:34 +0000 (14:34 -0700)
queue/series
queue/unregister_chrdev_region-semaphore-fix.patch [new file with mode: 0644]

index bb56ee6c33e865dfd2705dcf00ab7ea3c89eaeb2..6ad77622bec517585a24ce21080daa2f72555ffd 100644 (file)
@@ -1,2 +1,3 @@
 netfilter-connection-tracking.patch
+unregister_chrdev_region-semaphore-fix.patch
 trivial-v4l-cx88-video-hue-offset-fix.patch
diff --git a/queue/unregister_chrdev_region-semaphore-fix.patch b/queue/unregister_chrdev_region-semaphore-fix.patch
new file mode 100644 (file)
index 0000000..a1d93ec
--- /dev/null
@@ -0,0 +1,25 @@
+From stable-bounces@linux.kernel.org  Wed Jun 29 20:42:38 2005
+Date: Thu, 30 Jun 2005 11:42:10 +0800
+From: Wen-chien Jesse Sung <jesse@cola.voip.idv.tw>
+To: stable@kernel.org
+Subject: [PATCH] fix semaphore handling in __unregister_chrdev_region
+
+This up() should be down() instead.
+
+Signed-off-by: Wen-chien Jesse Sung <jesse@cola.voip.idv.tw>
+Signed-off-by: Chris Wright <chrisw@osdl.org>
+---
+
+Index: linux-2.6.12.y/fs/char_dev.c
+===================================================================
+--- linux-2.6.12.y.orig/fs/char_dev.c
++++ linux-2.6.12.y/fs/char_dev.c
+@@ -139,7 +139,7 @@ __unregister_chrdev_region(unsigned majo
+       struct char_device_struct *cd = NULL, **cp;
+       int i = major_to_index(major);
+-      up(&chrdevs_lock);
++      down(&chrdevs_lock);
+       for (cp = &chrdevs[i]; *cp; cp = &(*cp)->next)
+               if ((*cp)->major == major &&
+                   (*cp)->baseminor == baseminor &&