projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a570292
)
dyndbg: constify opt_array
author
Thomas Weißschuh
<linux@weissschuh.net>
Sun, 9 Jul 2023 21:17:58 +0000
(23:17 +0200)
committer
Greg Kroah-Hartman
<gregkh@linuxfoundation.org>
Fri, 4 Aug 2023 13:28:40 +0000
(15:28 +0200)
It is never modified, so mark it const.
Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Link:
https://lore.kernel.org/r/20230709-dyndbg-filename-v2-1-fd83beef0925@weissschuh.net
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
lib/dynamic_debug.c
patch
|
blob
|
history
diff --git
a/lib/dynamic_debug.c
b/lib/dynamic_debug.c
index fdd6d9800a7007141563de5feb5ebe26b9eedb68..71b22d206a1b22b2f519e7b6f9591d836539028d 100644
(file)
--- a/
lib/dynamic_debug.c
+++ b/
lib/dynamic_debug.c
@@
-88,7
+88,7
@@
static inline const char *trim_prefix(const char *path)
return path + skip;
}
-static struct { unsigned flag:8; char opt_char; } opt_array[] = {
+static
const
struct { unsigned flag:8; char opt_char; } opt_array[] = {
{ _DPRINTK_FLAGS_PRINT, 'p' },
{ _DPRINTK_FLAGS_INCL_MODNAME, 'm' },
{ _DPRINTK_FLAGS_INCL_FUNCNAME, 'f' },