apps/system: Update to print waitsem info in ps#7177
apps/system: Update to print waitsem info in ps#7177sunghan-chang merged 2 commits intoSamsung:masterfrom
Conversation
e0d0468 to
dee7088
Compare
dee7088 to
f5730ca
Compare
Thank you for the suggestion, I've split the commit. |
|
@seokhun-eom24 You added a new row for waitsem. But there are other waits like mq and signal.
|
Include waitsem, msgwaitq, sigwaitmask information into proc_entry_stat. Signed-off-by: seokhun-eom <seokhun.eom@samsung.com>
f5730ca to
2ce4ad4
Compare
Thank you for suggest. |
Add PROC_STAT_WAITINFO to get wait sem, mq, signal information from procfs.
Update to print wait information in ps command.
Update README for ps command output format.
[Example]
```
TASH>>ps
PID | PRIO | FLAG | TYPE | NP | STATUS | WAIT INFO | CPU | IRQCOUNT | NAME
------|------|------|---------|----|----------|------------|-----|----------|-----
mm_get_app_heap_name: address 0x60126400 is not in any app heap region.
0 | 0 | FIFO | KTHREAD | N | RUNNING | - | 0 | 0 | CPU0 IDLE
mm_get_app_heap_name: address 0x60126000 is not in any app heap region.
1 | 0 | FIFO | KTHREAD | N | RUNNING | - | 1 | 0 | CPU1 IDLE
mm_get_app_heap_name: address 0x60130c40 is not in any app heap region.
2 | 201 | RR | KTHREAD | | WAITSIG | 00020000 | 1 | 2 | hpwork
mm_get_app_heap_name: address 0x60132380 is not in any app heap region.
3 | 50 | RR | KTHREAD | | WAITSIG | 00020000 | 1 | 2 | lpwork
mm_get_app_heap_name: address 0x60136200 is not in any app heap region.
5 | 200 | RR | KTHREAD | | MQNEMPTY | 0x60136aa0 | 1 | 1 | km4_log_task
mm_get_app_heap_name: address 0x601b7b80 is not in any app heap region.
6 | 204 | RR | KTHREAD | | WAITSEM | 0x60191418 | 1 | 1 | LCD Frame flusing
mm_get_app_heap_name: address 0x601bb310 is not in any app heap region.
7 | 107 | RR | KTHREAD | | WAITSEM | 0x601ba3a0 | 1 | 1 | inic_msg_q_task
mm_get_app_heap_name: address 0x601bd2d0 is not in any app heap region.
8 | 104 | RR | KTHREAD | | WAITSEM | 0x601bc320 | 1 | 1 | inic_host_rx_tasklet
mm_get_app_heap_name: address 0x601bf2b0 is not in any app heap region.
9 | 103 | RR | KTHREAD | | WAITSEM | 0x601be2e0 | 1 | 1 | inic_ipc_api_host_task
mm_get_app_heap_name: address 0x601c24d0 is not in any app heap region.
11 | 100 | RR | KTHREAD | | WAITSIG | 00000000 | 1 | 2 | NDP_health_check
mm_get_app_heap_name: address 0x601d4da0 is not in any app heap region.
12 | 105 | RR | KTHREAD | | WAITSEM | 0x6011880c | 0 | 2 | LWIP_TCP/IP
mm_get_app_heap_name: address 0x601d6ce0 is not in any app heap region.
13 | 100 | RR | KTHREAD | | WAITSEM | 0x60117c74 | 0 | 1 | netmgr_event_handler
mm_get_app_heap_name: address 0x601d84c0 is not in any app heap region.
14 | 200 | RR | KTHREAD | | MQNEMPTY | 0x601db910 | 1 | 1 | log_dump
mm_get_app_heap_name: address 0x601decd0 is not in any app heap region.
15 | 203 | RR | KTHREAD | | MQNEMPTY | 0x601333d0 | 0 | 1 | binary_manager
18 | 180 | RR | TASK | | WAITSIG | 00000000 | 0 | 2 | app1
19 | 100 | RR | TASK | | WAITSIG | 00020000 | 0 | 1 | uwork
20 | 125 | RR | TASK | | WAITSEM | 0 | 0 | 1 | tash
21 | 100 | RR | PTHREAD | | WAITSEM | 0x63f82580 | 0 | 1 | PlayerWorker
22 | 100 | RR | PTHREAD | | WAITSEM | 0x63f82694 | 0 | 1 | RecorderWorker
23 | 100 | RR | PTHREAD | | WAITSEM | 0x63f8260c | 0 | 1 | PlayerObserverWorker
24 | 100 | RR | PTHREAD | | WAITSEM | 0x63f82714 | 0 | 1 | RecorderObserverWorker
25 | 199 | RR | PTHREAD | | WAITSEM | 0x63f82508 | 0 | 1 | FocusManagerWorker
26 | 100 | RR | TASK | | WAITSEM | 0x63a9008c | 0 | 1 | wifi msg handler
27 | 100 | RR | TASK | | WAITSEM | 0x63a917ac | 0 | 1 | ble msg handler
```
Signed-off-by: seokhun-eom <seokhun.eom@samsung.com>
2ce4ad4 to
65b97f6
Compare
| - FLAG : The policy of scheduling for each task/thread. | ||
| - TYPE : The type of task/thread. It can be KTHREAD(kernel thread), PTHREAD(user pthread) and TASK. | ||
| - NP : The flag of cancelable. | ||
| - STATUS : Current state of the task/thread. It can be PENDING, READYTORUN, RUNNING, etc. |
There was a problem hiding this comment.
@amandeep-samsung Regardless of this PR, could you add status description?
for example (need to rewrite it with proper English)
RUNNING : blah blah
MQNEMPTY : waiting status of message queue receiving
MQNFULL : waiting status to wait message queue available memory for sending
WAITSIG : blah blah
1. os/fs/procfs: Include wait info into proc_entry_stat
Include waitsem, msgwaitq, sigwaitmask information into proc_entry_stat.
2. apps/system: Update to print waitsem info in ps
Add PROC_STAT_WAITINFO to get wait sem, mq, signal information from procfs.
Update to print wait information in ps command.
Update README for ps command output format.
[Example]