[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen master] xen: rtds: Update last_start whenever cur_budget is updated



commit a418ec07cf2668197548c6503924139a2098e41d
Author:     Meng Xu <mengxu@xxxxxxxxxxxxx>
AuthorDate: Wed Oct 26 15:06:29 2016 -0400
Commit:     Wei Liu <wei.liu2@xxxxxxxxxx>
CommitDate: Thu Oct 27 14:58:18 2016 +0100

    xen: rtds: Update last_start whenever cur_budget is updated
    
    Make budget accounting code more consistent by making sure the values
    used to compute how much budget has been consumed are updated together.
    
    This makes code resilient to calling burn_budget() from more than just
    one place -- in case we will need to do that -- without risking subtle
    bugs.
    
    No functional changes are intended.
    
    Signed-off-by: Meng Xu <mengxu@xxxxxxxxxxxxx>
    Acked-by: Dario Faggioli <dario.faggioli@xxxxxxxxxx>
    Release-acked-by: Wei Liu <wei.liu2@xxxxxxxxxx>
---
 xen/common/sched_rt.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/xen/common/sched_rt.c b/xen/common/sched_rt.c
index 2119199..24b4b22 100644
--- a/xen/common/sched_rt.c
+++ b/xen/common/sched_rt.c
@@ -953,6 +953,7 @@ burn_budget(const struct scheduler *ops, struct rt_vcpu 
*svc, s_time_t now)
     }
 
     svc->cur_budget -= delta;
+    svc->last_start = now;
 
     if ( svc->cur_budget <= 0 )
     {
--
generated by git-patchbot for /home/xen/git/xen.git#master

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.