Skip to content
This repository has been archived by the owner on Aug 14, 2023. It is now read-only.

Commit

Permalink
sysinfo: Remove get_monotonic_boottime()
Browse files Browse the repository at this point in the history
get_monotonic_boottime() is deprecated because it uses the old 'timespec'
structure. This replaces one of the last callers with a call to
ktime_get_boottime.

Signed-off-by: Arnd Bergmann <[email protected]>
Signed-off-by: Thomas Gleixner <[email protected]>
Reviewed-by: Cyrill Gorcunov <[email protected]>
Cc: Andrew Morton <[email protected]>
Cc: [email protected]
Cc: Dominik Brodowski <[email protected]>
Cc: Cyrill Gorcunov <[email protected]>
Link: https://lkml.kernel.org/r/[email protected]
  • Loading branch information
arndb authored and KAGA-KOKO committed Jun 19, 2018
1 parent 58a1045 commit dc1b7b6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions kernel/sys.c
Original file line number Diff line number Diff line change
Expand Up @@ -2512,11 +2512,11 @@ static int do_sysinfo(struct sysinfo *info)
{
unsigned long mem_total, sav_total;
unsigned int mem_unit, bitcount;
struct timespec tp;
struct timespec64 tp;

memset(info, 0, sizeof(struct sysinfo));

get_monotonic_boottime(&tp);
ktime_get_boottime_ts64(&tp);
info->uptime = tp.tv_sec + (tp.tv_nsec ? 1 : 0);

get_avenrun(info->loads, 0, SI_LOAD_SHIFT - FSHIFT);
Expand Down

0 comments on commit dc1b7b6

Please sign in to comment.