summaryrefslogtreecommitdiffstats
path: root/drivers/base/bus.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2007-11-28 23:49:41 -0800
committerGreg Kroah-Hartman <gregkh@suse.de>2008-01-24 20:40:35 -0800
commit7dc72b2842381684b864750af31a5fb168dec764 (patch)
tree16746ac3f9836049705e1613480debb288c0068d /drivers/base/bus.c
parente5dd12784617f0f1fae5f96a7fac1ec4c49fadbe (diff)
downloadop-kernel-dev-7dc72b2842381684b864750af31a5fb168dec764.zip
op-kernel-dev-7dc72b2842381684b864750af31a5fb168dec764.tar.gz
Driver core: clean up debugging messages
The driver core debugging messages are a mess. This provides a unified message that makes them actually useful. The format for new kobject debug messages should be: driver/bus/class: 'OBJECT_NAME': FUNCTION_NAME: message.\n Note, the class code is not changed in this patch due to pending patches in my queue that this would conflict with. A later patch will clean them up. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/base/bus.c')
-rw-r--r--drivers/base/bus.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/base/bus.c b/drivers/base/bus.c
index aa0c986..937fc10 100644
--- a/drivers/base/bus.c
+++ b/drivers/base/bus.c
@@ -80,7 +80,7 @@ static void driver_release(struct kobject *kobj)
{
struct driver_private *drv_priv = to_driver(kobj);
- pr_debug("%s: freeing %s\n", __FUNCTION__, kobject_name(kobj));
+ pr_debug("driver: '%s': %s\n", kobject_name(kobj), __FUNCTION__);
kfree(drv_priv);
}
@@ -446,7 +446,7 @@ int bus_add_device(struct device * dev)
int error = 0;
if (bus) {
- pr_debug("bus %s: add device %s\n", bus->name, dev->bus_id);
+ pr_debug("bus: '%s': add device %s\n", bus->name, dev->bus_id);
error = device_add_attrs(bus, dev);
if (error)
goto out_put;
@@ -519,7 +519,7 @@ void bus_remove_device(struct device * dev)
dev->is_registered = 0;
klist_del(&dev->knode_bus);
}
- pr_debug("bus %s: remove device %s\n", dev->bus->name, dev->bus_id);
+ pr_debug("bus: '%s': remove device %s\n", dev->bus->name, dev->bus_id);
device_release_driver(dev);
bus_put(dev->bus);
}
@@ -637,7 +637,7 @@ int bus_add_driver(struct device_driver *drv)
if (!bus)
return -EINVAL;
- pr_debug("bus %s: add driver %s\n", bus->name, drv->name);
+ pr_debug("bus: '%s': add driver %s\n", bus->name, drv->name);
priv = kzalloc(sizeof(*priv), GFP_KERNEL);
if (!priv)
@@ -707,7 +707,7 @@ void bus_remove_driver(struct device_driver * drv)
driver_remove_attrs(drv->bus, drv);
driver_remove_file(drv, &driver_attr_uevent);
klist_remove(&drv->p->knode_bus);
- pr_debug("bus %s: remove driver %s\n", drv->bus->name, drv->name);
+ pr_debug("bus: '%s': remove driver %s\n", drv->bus->name, drv->name);
driver_detach(drv);
module_remove_driver(drv);
kobject_unregister(&drv->p->kobj);
@@ -907,7 +907,7 @@ int bus_register(struct bus_type * bus)
if (retval)
goto bus_attrs_fail;
- pr_debug("bus type '%s' registered\n", bus->name);
+ pr_debug("bus: '%s': registered\n", bus->name);
return 0;
bus_attrs_fail:
@@ -934,7 +934,7 @@ out:
*/
void bus_unregister(struct bus_type * bus)
{
- pr_debug("bus %s: unregistering\n", bus->name);
+ pr_debug("bus: '%s': unregistering\n", bus->name);
bus_remove_attrs(bus);
remove_probe_files(bus);
kset_unregister(bus->p->drivers_kset);
OpenPOWER on IntegriCloud