mirror-linux/kernel/debug/kdb
Thorsten Blum afdbe49276 kdb: Remove optional size arguments from strscpy() calls
If the destination buffer has a fixed length, strscpy() automatically
determines the size of the destination buffer using sizeof() if the
argument is omitted. This makes the explicit sizeof() unnecessary.

Furthermore, CMD_BUFLEN is equal to sizeof(kdb_prompt_str) and can also
be removed. Remove them to shorten and simplify the code.

No functional changes intended.

Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: Justin Stitt <justinstitt@google.com>
Link: https://lore.kernel.org/r/20250319163341.2123-2-thorsten.blum@linux.dev
Signed-off-by: Daniel Thompson <daniel@riscstar.com>
2025-03-28 21:28:28 +00:00
..
.gitignore .gitignore: add SPDX License Identifier 2020-03-25 11:50:48 +01:00
Makefile kdb: Get rid of broken attempt to print CCVERSION in kdb summary 2019-05-12 09:50:43 +01:00
kdb_bp.c kdb: Fix breakpoint enable to be silent if already enabled 2024-11-02 08:41:39 +00:00
kdb_bt.c kdb: Get rid of redundant kdb_curr_task() 2024-06-21 15:49:29 +01:00
kdb_cmds
kdb_debugger.c kdb: Get rid of custom debug heap allocator 2021-07-27 14:46:11 +01:00
kdb_io.c kdb: Remove optional size arguments from strscpy() calls 2025-03-28 21:28:28 +00:00
kdb_keyboard.c kdb: fix ctrl+e/a/f/b/d/p/n broken in keyboard mode 2024-11-18 15:20:22 +00:00
kdb_main.c kdb: remove usage of static environment buffer 2025-03-28 21:10:53 +00:00
kdb_private.h kdb: Get rid of redundant kdb_curr_task() 2024-06-21 15:49:29 +01:00
kdb_support.c kdb: Remove unused flags stack 2025-01-25 08:22:26 +00:00