Merge tag 'kgdb-5.15-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/danielt/linux
Pull kgdb updates from Daniel Thompson: "Changes for kgdb/kdb this cycle are dominated by a change from Sumit that removes as small (256K) private heap from kdb. This is change I've hoped for ever since I discovered how few users of this heap remained in the kernel, so many thanks to Sumit for hunting these down. The other change is an incremental step towards SPDX headers" * tag 'kgdb-5.15-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/danielt/linux: kernel: debug: Convert to SPDX identifier kdb: Rename members of struct kdbtab_t kdb: Simplify kdb_defcmd macro logic kdb: Get rid of redundant kdb_register_flags() kdb: Rename struct defcmd_set to struct kdb_macro kdb: Get rid of custom debug heap allocator
This commit is contained in:
+9
-11
@@ -28,28 +28,26 @@ static int kdb_hello_cmd(int argc, const char **argv)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static kdbtab_t hello_cmd = {
|
||||
.name = "hello",
|
||||
.func = kdb_hello_cmd,
|
||||
.usage = "[string]",
|
||||
.help = "Say Hello World or Hello [string]",
|
||||
};
|
||||
|
||||
static int __init kdb_hello_cmd_init(void)
|
||||
{
|
||||
/*
|
||||
* Registration of a dynamically added kdb command is done with
|
||||
* kdb_register() with the arguments being:
|
||||
* 1: The name of the shell command
|
||||
* 2: The function that processes the command
|
||||
* 3: Description of the usage of any arguments
|
||||
* 4: Descriptive text when you run help
|
||||
* 5: Number of characters to complete the command
|
||||
* 0 == type the whole command
|
||||
* 1 == match both "g" and "go" for example
|
||||
* kdb_register().
|
||||
*/
|
||||
kdb_register("hello", kdb_hello_cmd, "[string]",
|
||||
"Say Hello World or Hello [string]", 0);
|
||||
kdb_register(&hello_cmd);
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void __exit kdb_hello_cmd_exit(void)
|
||||
{
|
||||
kdb_unregister("hello");
|
||||
kdb_unregister(&hello_cmd);
|
||||
}
|
||||
|
||||
module_init(kdb_hello_cmd_init);
|
||||
|
||||
Reference in New Issue
Block a user