mirror of
https://github.com/systemd/systemd.git
synced 2024-10-31 07:51:21 +03:00
bootchart: use the bool type where appropriate
This commit is contained in:
parent
4155f7d4be
commit
a2715692e2
@ -881,21 +881,21 @@ static struct ps_struct *get_next_ps(struct ps_struct *ps) {
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int ps_filter(struct ps_struct *ps) {
|
static bool ps_filter(struct ps_struct *ps) {
|
||||||
if (!arg_filter)
|
if (!arg_filter)
|
||||||
return 0;
|
return false;
|
||||||
|
|
||||||
/* can't draw data when there is only 1 sample (need start + stop) */
|
/* can't draw data when there is only 1 sample (need start + stop) */
|
||||||
if (ps->first == ps->last)
|
if (ps->first == ps->last)
|
||||||
return -1;
|
return true;
|
||||||
|
|
||||||
/* don't filter kthreadd */
|
/* don't filter kthreadd */
|
||||||
if (ps->pid == 2)
|
if (ps->pid == 2)
|
||||||
return 0;
|
return false;
|
||||||
|
|
||||||
/* drop stuff that doesn't use any real CPU time */
|
/* drop stuff that doesn't use any real CPU time */
|
||||||
if (ps->total <= 0.001)
|
if (ps->total <= 0.001)
|
||||||
return -1;
|
return true;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user