[Devel] [PATCH RHEL7 COMMIT] ve: Use @real_start_timespec in uptime_proc_show

Konstantin Khorenko khorenko at virtuozzo.com
Thu Feb 11 01:02:13 PST 2016


The commit is pushed to "branch-rh7-3.10.0-327.3.1-vz7.10.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after rh7-3.10.0-327.3.1.vz7.10.10
------>
commit aca5e4ce483233884e9876a42ff41855f935f526
Author: Cyrill Gorcunov <gorcunov at virtuozzo.com>
Date:   Thu Feb 11 13:02:13 2016 +0400

    ve: Use @real_start_timespec in uptime_proc_show
    
    uptime_proc_show uses bootbased clocks so we should use
    @real_start_timespec here instead. Seems was a typo while
    converting from pcs6 code.
    
    In scope of
    https://jira.sw.ru/browse/PSBM-41406
    
    Signed-off-by: Cyrill Gorcunov <gorcunov at virtuozzo.com>
    Reviewed-by: Vladimir Davydov <vdavydov at virtuozzo.com>
    
    vdavydov@:
    This hunk was a part of
      diff-cpt-record-ct-boot-based-start-time-to-show-correct-uptime
    which was skipped during rebase to RH7 because it was considered cpt-related.
---
 fs/proc/uptime.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/proc/uptime.c b/fs/proc/uptime.c
index 1fa17c1..6fd5683 100644
--- a/fs/proc/uptime.c
+++ b/fs/proc/uptime.c
@@ -51,8 +51,8 @@ static int uptime_proc_show(struct seq_file *m, void *v)
 #ifdef CONFIG_VE
 	if (!ve_is_super(get_exec_env())) {
 		set_normalized_timespec(&uptime,
-			uptime.tv_sec - get_exec_env()->start_timespec.tv_sec,
-			uptime.tv_nsec - get_exec_env()->start_timespec.tv_nsec);
+			uptime.tv_sec - get_exec_env()->real_start_timespec.tv_sec,
+			uptime.tv_nsec - get_exec_env()->real_start_timespec.tv_nsec);
 	}
 #endif
 	seq_printf(m, "%lu.%02lu %lu.%02lu\n",


More information about the Devel mailing list