This is no specific issue of procps, it just returns the value from the kernel. The kernel documents (in the source) that the value includes the time spent in suspend.
/**
* ktime_get_boottime - Returns monotonic time since boot in ktime_t format
*
* This is similar to CLOCK_MONTONIC/ktime_get, but also includes the
* time spent in suspend.
*/
static inline ktime_t ktime_get_boottime(void)
{
return ktime_get_with_offset(TK_OFFS_BOOT);
}
This is no specific issue of procps, it just returns the value from the kernel. The kernel documents (in the source) that the value includes the time spent in suspend.
/proc/uptime gets the value from here:
https:/ /elixir. bootlin. com/linux/ v4.20.3/ source/ include/ linux/timekeepi ng.h#L93
/** ktime_get, but also includes the boottime( void) with_offset( TK_OFFS_ BOOT);
* ktime_get_boottime - Returns monotonic time since boot in ktime_t format
*
* This is similar to CLOCK_MONTONIC/
* time spent in suspend.
*/
static inline ktime_t ktime_get_
{
return ktime_get_
}