diff options
author | Tim Deegan <tim@xen.org> | 2013-08-20 15:01:47 +0200 |
---|---|---|
committer | Jan Beulich <jbeulich@suse.com> | 2013-08-20 15:01:47 +0200 |
commit | 0c98c1cbf24195ddbfc25caf72f42d56b432a5aa (patch) | |
tree | 73b3675b2e4e070ce09208ea2881b4f7f26ea6d5 | |
parent | d1e92ff4f98181eca51e39e9370b18c47f0607b6 (diff) | |
download | xen-0c98c1cbf24195ddbfc25caf72f42d56b432a5aa.tar.gz xen-0c98c1cbf24195ddbfc25caf72f42d56b432a5aa.tar.bz2 xen-0c98c1cbf24195ddbfc25caf72f42d56b432a5aa.zip |
x86/time: fix check for negative time in __update_vcpu_system_time()
Clang points out that u64 stime variable is always >= 0.
Signed-off-by: Tim Deegan <tim@xen.org>
master commit: ab7f9a793c78dfea81c037b34b0dd2db7070d8f8
master date: 2013-08-15 13:17:10 +0200
-rw-r--r-- | xen/arch/x86/time.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/xen/arch/x86/time.c b/xen/arch/x86/time.c index f047cb3074..c31029cb27 100644 --- a/xen/arch/x86/time.c +++ b/xen/arch/x86/time.c @@ -817,7 +817,8 @@ static void __update_vcpu_system_time(struct vcpu *v, int force) if ( d->arch.vtsc ) { - u64 stime = t->stime_local_stamp; + s_time_t stime = t->stime_local_stamp; + if ( is_hvm_domain(d) ) { struct pl_time *pl = &v->domain->arch.hvm_domain.pl_time; |