Function report |
Source Code:kernel\sched\cpuacct.c |
Create Date:2022-07-28 09:44:34 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:cpuacct_stats_show
Proto:static int cpuacct_stats_show(struct seq_file *sf, void *v)
Type:int
Parameter:
| Type | Parameter | Name |
|---|---|---|
| struct seq_file * | sf | |
| void * | v |
| 277 | for_each_possible_cpu(cpu) |
| 278 | u64 * cpustat = ({ |
| 278 | })->cpustat |
| 280 | val[... user mode ] += cpustat[CPUTIME_USER] |
| 281 | val[... user mode ] += cpustat[CPUTIME_NICE] |
| 282 | val[... kernel mode ] += cpustat[CPUTIME_SYSTEM] |
| 283 | val[... kernel mode ] += cpustat[CPUTIME_IRQ] |
| 284 | val[... kernel mode ] += cpustat[CPUTIME_SOFTIRQ] |
| 287 | When stat < CPUACCT_STAT_NSTATS cycle |
| 288 | seq_printf(sf, "%s %lld\n", cpuacct_stat_desc[stat], (longlong)nsec_to_clock_t(val[stat])) |
| 293 | 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 |