mirror of
https://github.com/xzeldon/htop.git
synced 2025-07-13 20:44:35 +03:00
OpenBSD: update
* Set process data for: - minflt - majflt - processor - nlwp * Drop unimplemented nlwp column * Scan userland threads * Mark a 'Thread is currently on a CPU.' with 'R', and processes 'Currently runnable' with 'P', do confine with man:ps(1) and Linux. See https://man.openbsd.org/ps.1 * Show CPU frequency
This commit is contained in:
@ -17,11 +17,18 @@ in the source distribution for its full text.
|
||||
|
||||
typedef struct OpenBSDProcess_ {
|
||||
Process super;
|
||||
|
||||
/* 'Kernel virtual addr of u-area' to detect main threads */
|
||||
uint64_t addr;
|
||||
} OpenBSDProcess;
|
||||
|
||||
#define Process_isKernelThread(_process) (_process->pgrp == 0)
|
||||
static inline bool Process_isKernelThread(const Process* this) {
|
||||
return this->pgrp == 0;
|
||||
}
|
||||
|
||||
#define Process_isUserlandThread(_process) (_process->pid != _process->tgid)
|
||||
static inline bool Process_isUserlandThread(const Process* this) {
|
||||
return this->pid != this->tgid;
|
||||
}
|
||||
|
||||
extern const ProcessClass OpenBSDProcess_class;
|
||||
|
||||
|
Reference in New Issue
Block a user