Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 45c64940 authored by Oleg Nesterov's avatar Oleg Nesterov Committed by Linus Torvalds
Browse files

kernel/sys.c:do_sysinfo(): use get_monotonic_boottime()



Change do_sysinfo() to use get_monotonic_boottime() instead of
do_posix_clock_monotonic_gettime() + monotonic_to_bootbased().

Signed-off-by: default avatarOleg Nesterov <oleg@redhat.com>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: default avatarJohn Stultz <johnstul@us.ibm.com>
Cc: Tomas Janousek <tjanouse@redhat.com>
Cc: Tomas Smetana <tsmetana@redhat.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 7ec75e1c
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -2355,8 +2355,7 @@ static int do_sysinfo(struct sysinfo *info)

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

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

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