Skip to contentSkip to conversation

tools/lib/lockdep: fixes for v4.15

PATCH In review [email protected] 2 participants 9 messages Dec 7, 2017 – Dec 11, 2017

lore
Share & tools
lore
#0 lore raw

cover tools/lib/lockdep: fixes for v4.15

The following changes since commit dabe589657ad0f9a0d6f4101e2171574f74b00bf:

Merge branch 'efi-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip (2017-12-06 15:20:51 -0800)

are available in the git repository at:

git://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux.git liblockdep-fixes

for you to fetch changes up to 97897d4c145c1e8431de28dc707dc0eda2e77037:

tools/lib/lockdep: add empty declaration for early_param (2017-12-06 22:37:52 -0500)

----------------------------------------------------------------
Mengting Zhang (1):
tools/lib/lockdep: Add missing declaration of 'pr_cont()'

Sasha Levin (1):
tools/lib/lockdep: add empty declaration for early_param

 tools/include/linux/kernel.h  | 2 ++
 tools/include/linux/lockdep.h | 1 +
 2 files changed, 3 insertions(+)

Mengting Zhang (1):
tools/lib/lockdep: Add missing declaration of 'pr_cont()'

Sasha Levin (1):
tools/lib/lockdep: add empty declaration for early_param

 tools/include/linux/kernel.h  | 2 ++
 tools/include/linux/lockdep.h | 1 +
 2 files changed, 3 insertions(+)
Signature · 1 line
2.11.0
#1 lore raw

PATCH 1/2 tools/lib/lockdep: Add missing declaration of 'pr_cont()'

From: Mengting Zhang <[email protected]>

An annoying compile warning due to missing declaration is shown below:
In file included from lockdep.c:27:0:
../../../kernel/locking/lockdep.c: In function 'print_unlock_imbalance_bug' :
../../../kernel/locking/lockdep.c:3544:2: warning: implicit declaration of function 'pr_cont' [-Wimplicit-function-declaration]
pr_cont(") at:\n");
^
Adding the declaration of 'pr_cont' fixes the problem.

---
 tools/include/linux/lockdep.h | 1 +
 1 file changed, 1 insertion(+)
tools/include/linux/lockdep.h +1 -0
index 940c1b075659..6b0c36a58fcb 100644
@@ -48,6 +48,7 @@ static inline int debug_locks_off(void)
 #define printk(...) dprintf(STDOUT_FILENO, __VA_ARGS__)
 #define pr_err(format, ...) fprintf (stderr, format, ## __VA_ARGS__)
 #define pr_warn pr_err
+#define pr_cont pr_err
 
 #define list_del_rcu list_del
 
Signature · 1 line
2.11.0
#2 lore raw

Re: [PATCH 1/2] tools/lib/lockdep: Add missing declaration of 'pr_cont()'

Quoted 8 lines · * [email protected] <[email protected]> wrote:

From: Mengting Zhang <[email protected]>

An annoying compile warning due to missing declaration is shown below:
In file included from lockdep.c:27:0:
../../../kernel/locking/lockdep.c: In function 'print_unlock_imbalance_bug' :
../../../kernel/locking/lockdep.c:3544:2: warning: implicit declaration of function 'pr_cont' [-Wimplicit-function-declaration]
pr_cont(") at:\n");
^

All build warnings are annoying, please formulate this in a more neutral fashion.

Also, please separate the compiler splat from the changelog text with an empty line, and align it vertically as well so that it seprates more.

Please do this for the second patch as well, and try to harmonize the style of the changelogs.

This is an example of a clean changelog that fixes a build warning:

commit 1b3b5219abfd6a214e99018747e9fe98514b43ca

Author: Arnaldo Carvalho de Melo <[email protected]>
Date:   Mon Nov 27 12:18:23 2017 -0300

tools headers: Syncronize mman.h ABI header

To add support for the MAP_SYNC flag introduced in:

b6fb293f2497 ("mm: Define MAP_SYNC and VM_SYNC flags")

Update tools/perf/trace/beauty/mmap.c to support that flag.

This silences this perf build warning:

Warning: Kernel ABI header at 'tools/include/uapi/asm-generic/mman.h' differs from latest version at 'include/uapi/asm-generic/mman.h'

Thanks,

Ingo

#3 lore raw

PATCH 2/2 tools/lib/lockdep: add empty declaration for early_param

In reply to [email protected]

Fixes a compilation error:

CC lockdep.o
In file included from lockdep.c:28:0:
../../../kernel/locking/lockdep.c:89:13: error: expected declaration specifiers or ‘...’ before string constant

 early_param("crossrelease_fullstack", allow_crossrelease_fullstack);
             ^~~~~~~~~~~~~~~~~~~~~~~~
../../../kernel/locking/lockdep.c:89:39: error: expected declaration specifiers or ‘...’ before ‘allow_crossrelease_fullstack’
 early_param("crossrelease_fullstack", allow_crossrelease_fullstack);
                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
---
 tools/include/linux/kernel.h | 2 ++
 1 file changed, 2 insertions(+)
tools/include/linux/kernel.h +2 -0
index 0ad884452c5c..2bd8c1fc4a03 100644
@@ -117,4 +117,6 @@ int scnprintf(char * buf, size_t size, const char * fmt, ...);
 #define current_gfp_context(k) 0
 #define synchronize_sched()
 
+#define early_param(str, fn)
+
 #endif
Signature · 1 line
2.11.0
#4 lore raw

Re: [PATCH 2/2] tools/lib/lockdep: add empty declaration for early_param

Quoted 10 lines · * [email protected] <[email protected]> wrote:

Fixes a compilation error:

CC lockdep.o
In file included from lockdep.c:28:0:
../../../kernel/locking/lockdep.c:89:13: error: expected declaration specifiers or ‘...’ before string constant

 early_param("crossrelease_fullstack", allow_crossrelease_fullstack);
             ^~~~~~~~~~~~~~~~~~~~~~~~
../../../kernel/locking/lockdep.c:89:39: error: expected declaration specifiers or ‘...’ before ‘allow_crossrelease_fullstack’
 early_param("crossrelease_fullstack", allow_crossrelease_fullstack);
                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~

Ugh, this changelog was in DOS format (had extra \r's) - how did that happen?

Fixed it up.

Thanks,

Ingo

#5 lore raw

Re: [PATCH 2/2] tools/lib/lockdep: add empty declaration for early_param

Quoted 14 lines · Ingo Molnar
Quoted 10 lines · * [email protected] <[email protected]> wrote:

Fixes a compilation error:

CC lockdep.o
In file included from lockdep.c:28:0:
../../../kernel/locking/lockdep.c:89:13: error: expected declaration specifiers or ‘...’ before string constant

 early_param("crossrelease_fullstack", allow_crossrelease_fullstack);
             ^~~~~~~~~~~~~~~~~~~~~~~~
../../../kernel/locking/lockdep.c:89:39: error: expected declaration specifiers or ‘...’ before ‘allow_crossrelease_fullstack’
 early_param("crossrelease_fullstack", allow_crossrelease_fullstack);
                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
Quoted 1 line

Ugh, this changelog was in DOS format (had extra \r's) - how did that happen?

Hm, so it's because the second patch email was sent as as a base64 encoded email:

Content-Transfer-Encoding: base64

totally not recommended and git-send-email will not do that - what happened?

Quoted 2 lines

Fixed it up.

Actually, could you please resend the whole series, with a fix for the other warning I reported added, with the changelogs fixed, and not MIME encoded?

Thanks,

Ingo

#6 lore raw

Re: [PATCH 2/2] tools/lib/lockdep: add empty declaration for early_param

Quoted 17 lines · Ingo Molnar
Quoted 14 lines · Ingo Molnar
Quoted 10 lines · * [email protected] <[email protected]> wrote:

Fixes a compilation error:

CC lockdep.o
In file included from lockdep.c:28:0:
../../../kernel/locking/lockdep.c:89:13: error: expected declaration specifiers or ‘...’ before string constant

 early_param("crossrelease_fullstack", allow_crossrelease_fullstack);
             ^~~~~~~~~~~~~~~~~~~~~~~~
../../../kernel/locking/lockdep.c:89:39: error: expected declaration specifiers or ‘...’ before ‘allow_crossrelease_fullstack’
 early_param("crossrelease_fullstack", allow_crossrelease_fullstack);
                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
Quoted 7 lines
Quoted 1 line

Ugh, this changelog was in DOS format (had extra \r's) - how did that happen?

Hm, so it's because the second patch email was sent as as a base64 encoded email:

Content-Transfer-Encoding: base64

totally not recommended and git-send-email will not do that - what happened?

I'm not sure, this was sent using git-send-email...

Quoted 5 lines
Quoted 2 lines

Fixed it up.

Actually, could you please resend the whole series, with a fix for the other warning I reported added, with the changelogs fixed, and not MIME encoded?

Sure!

Signature · 2 lines
Thanks,
Sasha
#7 lore raw

Re: [PATCH 2/2] tools/lib/lockdep: add empty declaration for early_param

Quoted 20 lines · * [email protected] <[email protected]> wrote:
Quoted 19 lines · Ingo Molnar
Quoted 15 lines · Ingo Molnar
Quoted 10 lines · * [email protected] <[email protected]> wrote:

Fixes a compilation error:

CC lockdep.o
In file included from lockdep.c:28:0:
../../../kernel/locking/lockdep.c:89:13: error: expected declaration specifiers or ‘...’ before string constant

 early_param("crossrelease_fullstack", allow_crossrelease_fullstack);
             ^~~~~~~~~~~~~~~~~~~~~~~~
../../../kernel/locking/lockdep.c:89:39: error: expected declaration specifiers or ‘...’ before ‘allow_crossrelease_fullstack’
 early_param("crossrelease_fullstack", allow_crossrelease_fullstack);
                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~

Ugh, this changelog was in DOS format (had extra \r's) - how did that happen?

Quoted 7 lines
Quoted 5 lines

Hm, so it's because the second patch email was sent as as a base64 encoded email:

Content-Transfer-Encoding: base64

totally not recommended and git-send-email will not do that - what happened?

I'm not sure, this was sent using git-send-email...

Weird - will let you know if it happens again.

Thanks,

Ingo

#8 lore raw
In reply to [email protected]
Quoted 26 lines · * [email protected] <[email protected]> wrote:

The following changes since commit dabe589657ad0f9a0d6f4101e2171574f74b00bf:

Merge branch 'efi-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip (2017-12-06 15:20:51 -0800)

are available in the git repository at:

git://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux.git liblockdep-fixes

for you to fetch changes up to 97897d4c145c1e8431de28dc707dc0eda2e77037:

tools/lib/lockdep: add empty declaration for early_param (2017-12-06 22:37:52 -0500)

----------------------------------------------------------------
Mengting Zhang (1):
tools/lib/lockdep: Add missing declaration of 'pr_cont()'

Sasha Levin (1):
tools/lib/lockdep: add empty declaration for early_param

 tools/include/linux/kernel.h  | 2 ++
 tools/include/linux/lockdep.h | 1 +
 2 files changed, 3 insertions(+)

Mengting Zhang (1):
tools/lib/lockdep: Add missing declaration of 'pr_cont()'

Quoted 6 lines

Sasha Levin (1):
tools/lib/lockdep: add empty declaration for early_param

 tools/include/linux/kernel.h  | 2 ++
 tools/include/linux/lockdep.h | 1 +
 2 files changed, 3 insertions(+)

There's this build warning as well:

triton:~/tip/tools/lib/lockdep> make
CC common.o
CC lockdep.o
In file included from lockdep.c:28:0:
../../../kernel/locking/lockdep.c:83:19: warning: ‘allow_crossrelease_fullstack’ defined but not used [-Wunused-function]
static int __init allow_crossrelease_fullstack(char *str)

                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~

GCC 7.2.0.

Thanks,

Ingo