From: Chris Wright Date: Thu, 30 Jun 2005 21:34:34 +0000 (-0700) Subject: Add unregister_chrdev_region-semaphore-fix.patch from Wen-chien Jesse Sung X-Git-Tag: v2.6.12.3~13 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=289583c4a6d88f0066fcd68aaf329c0f59886089;p=thirdparty%2Fkernel%2Fstable-queue.git Add unregister_chrdev_region-semaphore-fix.patch from Wen-chien Jesse Sung --- diff --git a/queue/series b/queue/series index bb56ee6c33e..6ad77622bec 100644 --- a/queue/series +++ b/queue/series @@ -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 index 00000000000..a1d93ec1d0b --- /dev/null +++ b/queue/unregister_chrdev_region-semaphore-fix.patch @@ -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 +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 +Signed-off-by: Chris Wright +--- + +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 &&