From 45fb394a3248b3548579bd7a5d1e3c8d3aadd8db Mon Sep 17 00:00:00 2001 From: Debarshi Dutta Date: Wed, 12 Apr 2023 10:08:59 +0000 Subject: mali_kbase: Remove incorrect WARN() The WARN() call at the beginning of the function schedule_on_tick() is incorrect as kbase_gpu_interrupt() might enqueue another tick_work(2) into the scheduler before the already inflight worker tick_work(1) sets the tick_timer_active variable to true. This could result in a condition where the hrtimer hasn't still expired and tick_work(1) starts executing resulting in the WARN_ON() being fired. The timer works asynchronously with the tick_work() and hence this warning can be removed from here. Bug 207824944 Change-Id: I873624c76b0de102bbcdd451a8402cb1c096edda --- mali_kbase/csf/mali_kbase_csf_scheduler.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'mali_kbase') diff --git a/mali_kbase/csf/mali_kbase_csf_scheduler.c b/mali_kbase/csf/mali_kbase_csf_scheduler.c index d923238..e472dba 100644 --- a/mali_kbase/csf/mali_kbase_csf_scheduler.c +++ b/mali_kbase/csf/mali_kbase_csf_scheduler.c @@ -384,7 +384,6 @@ static void start_tick_timer(struct kbase_device *kbdev) lockdep_assert_held(&scheduler->lock); spin_lock_irqsave(&scheduler->interrupt_lock, flags); - WARN_ON(scheduler->tick_timer_active); if (likely(!scheduler->tick_timer_active)) { scheduler->tick_timer_active = true; @@ -5682,7 +5681,6 @@ static void schedule_on_tick(struct kthread_work *work) mutex_lock(&scheduler->lock); - WARN_ON(scheduler->tick_timer_active); if (can_skip_scheduling(kbdev)) goto exit_no_schedule_unlock; -- cgit v1.2.3