Function report | 
Source Code:kernel\debug\kdb\kdb_main.c | 
Create Date:2022-07-28 11:42:13 | 
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick | 
| home page | Tree | 
| Annotation kernel can get tool activity | Download SCCT | Chinese | 
Name:kdb_pid - This function implements the 'pid' command which switches* the currently active process.* pid [<pid> | R]
Proto:static int kdb_pid(int argc, const char **argv)
Type:int
Parameter:
| Type | Parameter | Name | 
|---|---|---|
| int | argc | |
| const char ** | argv | 
| 2389 | If argc > 1 Then Return KDB_ARGCOUNT | 
| 2392 | If argc Then | 
| 2394 | p = KDB_TSK(cpu number that owns kdb ) | 
| 2395 | Else | 
| 2397 | If diag Then Return KDB_BADINT | 
| 2401 | If Not p Then | 
| 2402 | kdb_printf("No task with pid=%d\n", (pid_t)val) | 
| 2403 | Return 0 | 
| 2406 | kdb_set_current_task(p) | 
| 2408 | kdb_printf("KDB current process is %s(pid=%d)\n", * executable name, excluding path. * - normally initialized setup_new_exec() * - access it with [gs]et_task_comm() * - lock it with task_lock(), process id) | 
| 2412 | Return 0 | 
| Source code conversion tool public plug-in interface  | X | 
|---|---|
| Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion  |