sched: walt: Add BUG_ON() when wallclock goes backwards
This reverts 'commit b5e1207658f0 ("ANDROID: arch_timer: add error
handling when the MPM global timer is cleared")'
The above mentioned commit removed a BUG_ON() which gets hit, when
the wallclock goes backwards compared to the rq->window_start. This
condition is fatal for WALT accounting. The update_task_ravg() strictly
expects the wallclock - rq->window_start to be positive and when it
becomes negative, the accounting issues would show up at later point
of time which makes debugging difficult.
This BUG_ON() is a false positive only when the MPM global timer is
cleared and CPUs are running for a short time during force reset. It
is very easy to identify this condition than debugging the scheduler
accounting and time going backwards issues. So add the BUG_ON() back.
Change-Id: Ib52862abb9448dc6db70bb7db958d11545db095f
Signed-off-by:
Pavankumar Kondeti <pkondeti@codeaurora.org>
Signed-off-by:
Lingutla Chandrasekhar <clingutla@codeaurora.org>
Loading
Please register or sign in to comment