* [PATCH] fix transport class corner case after rework
@ 2005-08-15 21:13 James Bottomley
0 siblings, 0 replies; only message in thread
From: James Bottomley @ 2005-08-15 21:13 UTC (permalink / raw)
To: SCSI Mailing List
If your transport class sets the ATTRIBUTE_CONTAINER_NO_CLASSDEVS flag,
then its configure method never gets called. This patch fixes that so
that the configure method is called with a NULL classdev.
Also remove a spurious inverted comma in the transport_class comments.
James
diff --git a/drivers/base/attribute_container.c b/drivers/base/attribute_container.c
--- a/drivers/base/attribute_container.c
+++ b/drivers/base/attribute_container.c
@@ -237,6 +237,11 @@ attribute_container_device_trigger(struc
if (!cont->match(cont, dev))
continue;
+ if (attribute_container_no_classdevs(cont)) {
+ fn(cont, dev, NULL);
+ continue;
+ }
+
spin_lock(&cont->containers_lock);
list_for_each_entry_safe(ic, tmp, &cont->containers, node) {
if (dev == ic->classdev.dev)
diff --git a/drivers/base/transport_class.c b/drivers/base/transport_class.c
--- a/drivers/base/transport_class.c
+++ b/drivers/base/transport_class.c
@@ -7,7 +7,7 @@
* This file is licensed under GPLv2
*
* The basic idea here is to allow any "device controller" (which
- * would most often be a Host Bus Adapter" to use the services of one
+ * would most often be a Host Bus Adapter to use the services of one
* or more tranport classes for performing transport specific
* services. Transport specific services are things that the generic
* command layer doesn't want to know about (speed settings, line
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2005-08-15 21:13 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-08-15 21:13 [PATCH] fix transport class corner case after rework James Bottomley
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox