Re: [Freedreno] [PATCH 2/2] drm/scheduler: Add a start_timeout_notify() backend function

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

 



[SNIP]

Am 05.11.18 um 08:55 schrieb Sharat Masetty:
> Hi Christian,
>
> Yes something like a suspend timeout would be simpler for the drivers, 
> but I could not find anything which does this for the delayed work or 
> even for the general timers. All I could find was cancel/delete.
>
> In lieu of this, I chose this approach. If you like it this 
> way(proposed patch), then I will address the review comments and 
> re-spin... please let me know.
>
> Sharat

I think I would prefer investigating into the suspend/resume approach 
for a moment.

What we can do rather easily is to use mod_delayed_work() with a larger 
timeout, e.g. like the following:

void drm_sched_suspend_timeout()
{
     mod_delayed_work(&sched->work_tdr, sched->timeout * 10);
}

void drm_sched_resume_timeout()
{
     mod_delayed_work(&sched->work_tdr, sched->timeout);
}

By looking at work_tdr.timer.expires before modifying it 
drm_sched_suspend_timeout() could also return the remaining jiffies to wait.

This way we wouldn't need to restart the timeout completely on every resume.

Regards,
Christian.
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux