From 8ccd314035a0a1332b466acdef027005dc9da164 Mon Sep 17 00:00:00 2001 From: Dan Williams Date: Fri, 6 Apr 2012 13:41:15 -0700 Subject: [PATCH] --- yaml --- r: 299092 b: refs/heads/master c: 282029c005e65ffdce3aa9f8220f88a8bbbc4dae h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/lib/kobject.c | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/[refs] b/[refs] index 224187dcbf73..8cf84fd02b9d 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 3a198886ab5f228fcbebb9ace803d8b99721d49a +refs/heads/master: 282029c005e65ffdce3aa9f8220f88a8bbbc4dae diff --git a/trunk/lib/kobject.c b/trunk/lib/kobject.c index 21dee7c19afd..aeefa8bc8b1c 100644 --- a/trunk/lib/kobject.c +++ b/trunk/lib/kobject.c @@ -192,14 +192,14 @@ static int kobject_add_internal(struct kobject *kobj) /* be noisy on error issues */ if (error == -EEXIST) - printk(KERN_ERR "%s failed for %s with " - "-EEXIST, don't try to register things with " - "the same name in the same directory.\n", - __func__, kobject_name(kobj)); + WARN(1, "%s failed for %s with " + "-EEXIST, don't try to register things with " + "the same name in the same directory.\n", + __func__, kobject_name(kobj)); else - printk(KERN_ERR "%s failed for %s (%d)\n", - __func__, kobject_name(kobj), error); - dump_stack(); + WARN(1, "%s failed for %s (error: %d parent: %s)\n", + __func__, kobject_name(kobj), error, + parent ? kobject_name(parent) : "'none'"); } else kobj->state_in_sysfs = 1;