Skip to content

Commit c7153d0

Browse files
committed
Merge tag 'driver-core-3.10-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core
Pull driver core fixes from Greg Kroah-Hartman: "Here are 3 tiny driver core fixes for 3.10-rc2. A needed symbol export, a change to make it easier to track down offending sysfs files with incorrect attributes, and a klist bugfix. All have been in linux-next for a while" * tag 'driver-core-3.10-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: klist: del waiter from klist_remove_waiters before wakeup waitting process driver core: print sysfs attribute name when warning about bogus permissions driver core: export subsys_virtual_register
2 parents 5cc0c03 + ac5a296 commit c7153d0

3 files changed

Lines changed: 6 additions & 3 deletions

File tree

‎drivers/base/bus.c‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1295,6 +1295,7 @@ int subsys_virtual_register(struct bus_type *subsys,
12951295

12961296
return subsys_register(subsys, groups, virtual_dir);
12971297
}
1298+
EXPORT_SYMBOL_GPL(subsys_virtual_register);
12981299

12991300
int __init buses_init(void)
13001301
{

‎drivers/base/core.c‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -572,9 +572,11 @@ int device_create_file(struct device *dev,
572572

573573
if (dev) {
574574
WARN(((attr->attr.mode & S_IWUGO) && !attr->store),
575-
"Write permission without 'store'\n");
575+
"Attribute %s: write permission without 'store'\n",
576+
attr->attr.name);
576577
WARN(((attr->attr.mode & S_IRUGO) && !attr->show),
577-
"Read permission without 'show'\n");
578+
"Attribute %s: read permission without 'show'\n",
579+
attr->attr.name);
578580
error = sysfs_create_file(&dev->kobj, &attr->attr);
579581
}
580582

‎lib/klist.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,10 +193,10 @@ static void klist_release(struct kref *kref)
193193
if (waiter->node != n)
194194
continue;
195195

196+
list_del(&waiter->list);
196197
waiter->woken = 1;
197198
mb();
198199
wake_up_process(waiter->process);
199-
list_del(&waiter->list);
200200
}
201201
spin_unlock(&klist_remove_lock);
202202
knode_set_klist(n, NULL);

0 commit comments

Comments
 (0)