[kernel/f15] bsg: fix sysfs link remove warning (#787862)
Dave Jones
davej at fedoraproject.org
Thu Feb 9 20:42:09 UTC 2012
commit c93c7e5a024ba4a748cd86bb4d59d96e0aa197fa
Author: Dave Jones <davej at redhat.com>
Date: Thu Feb 9 15:41:58 2012 -0500
bsg: fix sysfs link remove warning (#787862)
bsg-fix-sysfs-link-remove-warning.patch | 16 ++++++++++++++++
kernel.spec | 9 ++++++++-
2 files changed, 24 insertions(+), 1 deletions(-)
---
diff --git a/bsg-fix-sysfs-link-remove-warning.patch b/bsg-fix-sysfs-link-remove-warning.patch
new file mode 100644
index 0000000..6e76253
--- /dev/null
+++ b/bsg-fix-sysfs-link-remove-warning.patch
@@ -0,0 +1,16 @@
+diff --git a/block/bsg.c b/block/bsg.c
+index 4cf703f..ff64ae3 100644
+--- a/block/bsg.c
++++ b/block/bsg.c
+@@ -983,7 +983,8 @@ void bsg_unregister_queue(struct request_queue *q)
+
+ mutex_lock(&bsg_mutex);
+ idr_remove(&bsg_minor_idr, bcd->minor);
+- sysfs_remove_link(&q->kobj, "bsg");
++ if (q->kobj.sd)
++ sysfs_remove_link(&q->kobj, "bsg");
+ device_unregister(bcd->class_dev);
+ bcd->class_dev = NULL;
+ kref_put(&bcd->ref, bsg_kref_release_function);
+--
+1.7.4.4
diff --git a/kernel.spec b/kernel.spec
index 7f68504..a0d1a18 100644
--- a/kernel.spec
+++ b/kernel.spec
@@ -644,6 +644,8 @@ Patch12016: disable-i8042-check-on-apple-mac.patch
Patch12025: block-readahead-block-plug.patch
+Patch12026: bsg-fix-sysfs-link-remove-warning.patch
+
Patch12030: epoll-limit-paths.patch
Patch12303: dmar-disable-when-ricoh-multifunction.patch
@@ -1248,6 +1250,8 @@ ApplyPatch disable-i8042-check-on-apple-mac.patch
ApplyPatch epoll-limit-paths.patch
ApplyPatch block-readahead-block-plug.patch
+ApplyPatch bsg-fix-sysfs-link-remove-warning.patch
+
# rhbz#605888
ApplyPatch dmar-disable-when-ricoh-multifunction.patch
@@ -1946,7 +1950,10 @@ fi
# and build.
%changelog
-* Wed Feb 08 2012 Josh Boyer <jwboyer at redhat.com>
+* Thu Feb 09 2012 Dave Jones <davej at redhat.com>
+- bsg: fix sysfs link remove warning (#787862)
+
+* Wed Feb 08 2012 Josh Boyer <jwboyer at redhat.com> 2.6.42.3-2.fc15
- CVE-2011-4086: jbd2: unmapped buffer with _Unwritten or _Delay flags
set can lead to DoS (rhbz 788260)
- Drop patch that was NAKd upstream (rhbz 783211)
More information about the scm-commits
mailing list