Skip to contentSkip to conversation

lockdep: Add missing space in error message

PATCH In review Borislav Petkov 3 participants 4 messages May 29, 2015 – Jun 3, 2015 Locking primitives

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 lockdep: Add missing space in error message

From: Borislav Petkov <[email protected]>

... to fix this:

WARNING: lockdep init error! lock-(console_sem).lock was acquiredbefore lockdep_init

---
 kernel/locking/lockdep.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/locking/lockdep.c +1 -1
index a0831e1b99f4..041ac1add184 100644
@@ -4066,7 +4066,7 @@ void __init lockdep_info(void)
 
 #ifdef CONFIG_DEBUG_LOCKDEP
 	if (lockdep_init_error) {
-		printk("WARNING: lockdep init error! lock-%s was acquired"
+		printk("WARNING: lockdep init error! lock-%s was acquired "
 			"before lockdep_init\n", lock_init_error);
 		printk("Call stack leading to lockdep invocation was:\n");
 		print_stack_trace(&lockdep_init_trace, 0);
Signature · 1 line
2.3.5
#1 lore raw
Quoted 16 lines · Borislav Petkov

From: Borislav Petkov <[email protected]>

... to fix this:

WARNING: lockdep init error! lock-(console_sem).lock was acquiredbefore lockdep_init

---
 kernel/locking/lockdep.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/locking/lockdep.c +0 -0
index a0831e1b99f4..041ac1add184 100644

kernel/locking/lockdep.c void __init lockdep_info(void) · line 4070

Quoted 6 lines
kernel/locking/lockdep.c +1 -1
@@ -4066,7 +4066,7 @@ void __init lockdep_info(void)
 
 #ifdef CONFIG_DEBUG_LOCKDEP
 	if (lockdep_init_error) {
-		printk("WARNING: lockdep init error! lock-%s was acquired"
+		printk("WARNING: lockdep init error! lock-%s was acquired "
 			"before lockdep_init\n", lock_init_error);

Please also fix the cause, not just the symptom: the cause is the unnecessary line-break in the middle of a user visible string.

Thanks,

Ingo

#2 lore raw

PATCH 1/1 lockdep: Do not break user-visible string

Quoted 2 lines · Ingo Molnar

Please also fix the cause, not just the symptom: the cause is the unnecessary line-break in the middle of a user visible string.

v1.1:

---
From: Borislav Petkov <[email protected]>
Date: Fri, 29 May 2015 18:49:45 +0200
Subject: [PATCH v1.1] lockdep: Do not break user-visible string

Remove the line-break in the user-visible string and add the missing space in this error message:

WARNING: lockdep init error! lock-(console_sem).lock was acquiredbefore lockdep_init

---
 kernel/locking/lockdep.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
kernel/locking/lockdep.c +1 -2
index a0831e1b99f4..4f0b995d86a2 100644
@@ -4066,8 +4066,7 @@ void __init lockdep_info(void)
 
 #ifdef CONFIG_DEBUG_LOCKDEP
 	if (lockdep_init_error) {
-		printk("WARNING: lockdep init error! lock-%s was acquired"
-			"before lockdep_init\n", lock_init_error);
+		printk("WARNING: lockdep init error! lock-%s was acquired before lockdep_init\n", lock_init_error);
 		printk("Call stack leading to lockdep invocation was:\n");
 		print_stack_trace(&lockdep_init_trace, 0);
 	}
Signature · 8 lines
2.3.5

-- 
Regards/Gruss,
    Boris.

ECO tip #101: Trim your mails when you reply.
--
#3 lore raw

[tip:locking/core] lockdep: Do not break user-visible string

lockdep: Do not break user-visible string
Commit-ID:  92ae18371cb1abb4e186dd9d48de2bb0d9bba626
Gitweb:     http://git.kernel.org/tip/92ae18371cb1abb4e186dd9d48de2bb0d9bba626
Author:     Borislav Petkov <[email protected]>
AuthorDate: Tue, 2 Jun 2015 15:38:27 +0200
Committer:  Ingo Molnar <[email protected]>
CommitDate: Wed, 3 Jun 2015 10:07:09 +0200

lockdep: Do not break user-visible string

Remove the line-break in the user-visible string and add the missing space in this error message:

WARNING: lockdep init error! lock-(console_sem).lock was acquiredbefore lockdep_init

Also:

- don't yell, it's just a debug warning

- denote references to function calls with '()'

- standardize the lock name quoting

- and finish the sentence.

The result:

WARNING: lockdep init error: lock '(console_sem).lock' was acquired before lockdep_init().

Cc Andrew Morton <[email protected]>
Cc Linus Torvalds <[email protected]>
Cc Paul E. McKenney <[email protected]>
Cc Peter Zijlstra <[email protected]>
Cc Peter Zijlstra <[email protected]>
Cc Thomas Gleixner <[email protected]>
[ Added a few more stylistic tweaks to the error message. ]
---
 kernel/locking/lockdep.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
kernel/locking/lockdep.c +1 -2
index a0831e1..a61bb1d3 100644
@@ -4066,8 +4066,7 @@ void __init lockdep_info(void)
 
 #ifdef CONFIG_DEBUG_LOCKDEP
 	if (lockdep_init_error) {
-		printk("WARNING: lockdep init error! lock-%s was acquired"
-			"before lockdep_init\n", lock_init_error);
+		printk("WARNING: lockdep init error: lock '%s' was acquired before lockdep_init().\n", lock_init_error);
 		printk("Call stack leading to lockdep invocation was:\n");
 		print_stack_trace(&lockdep_init_trace, 0);
 	}