diff options
| author | ruki <[email protected]> | 2022-07-29 22:38:30 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2022-07-29 22:38:30 +0800 |
| commit | 2d782164c5c5d412890fbae2d4b72971c3239dc5 (patch) | |
| tree | 218d5df7257ed0f96cc1fd3214cee8e4c7e04aff /core/src | |
| parent | 152c65d1c13322788fd6eb8cb5569b704164a58b (diff) | |
get cpuinfo for bsd
Diffstat (limited to 'core/src')
| -rw-r--r-- | core/src/xmake/os/cpuinfo.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/src/xmake/os/cpuinfo.c b/core/src/xmake/os/cpuinfo.c index 618caf15f..e5d27a0f3 100644 --- a/core/src/xmake/os/cpuinfo.c +++ b/core/src/xmake/os/cpuinfo.c @@ -208,8 +208,8 @@ static tb_float_t xm_os_cpuinfo_usagerate() tb_long_t idle = states[CP_IDLE]; tb_trace_i("%ld %ld %ld %ld %ld", user, nice, sys, intr, idle); - tb_int64_t active = user + nice + sys + irq + softirq + steal + guest + guest_nice; - tb_int64_t total = user + nice + sys + idle + iowait + irq + softirq + steal + guest + guest_nice; + tb_int64_t active = user + nice + sys + intr; + tb_int64_t total = user + nice + sys + idle + intr; if (total_prev > 0 && active_prev > 0) { tb_int64_t total_diff = total - total_prev; |
