Re: [PATCH 1/2] drm/radeon: Don't hang in radeon_flip_work_func on disabled crtc. (v2)

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

 



On Thu, Feb 18, 2016 at 8:16 PM, Michel Dänzer <michel@xxxxxxxxxxx> wrote:
> On 19.02.2016 10:06, Mario Kleiner wrote:
>> This fixes a regression introduced in Linux 4.4.
>>
>> Limit the amount of time radeon_flip_work_func can
>> delay programming a page flip, by both limiting the
>> maximum amount of time per wait cycle and the maximum
>> number of wait cycles. Continue the flip if the limit
>> is exceeded, even if that may result in a visual or
>> timing glitch.
>>
>> This is to prevent a hang of page flips, as reported
>> in fdo bug #93746: Disconnecting a DisplayPort display
>> in parallel to a kms pageflip getting queued can cause
>> the following hang of page flips and thereby an unusable
>> desktop:
>>
>> 1. kms pageflip ioctl() queues pageflip -> queues execution
>>    of radeon_flip_work_func.
>>
>> 2. Hotunplug of display causes the driver to DPMS OFF
>>    the unplugged display. Display engine shuts down,
>>    scanout no longer moves, but stays at its resting
>>    position at start line of vblank.
>>
>> 3. radeon_flip_work_func executes while crtc is off, and
>>    due to the non-moving scanout position, the new flip
>>    delay code introduced into Linux 4.4 by
>>    commit 5b5561b3660d ("drm/radeon: Fixup hw vblank counter/ts..")
>>    enters an infinite wait loop.
>>
>> 4. After reconnecting the display, the pageflip continues
>>    to hang in 3. and the display doesn't update its view
>>    of the desktop.
>>
>> This patch fixes the Linux 4.4 regression from fdo bug #93746
>>
>> <https://bugs.freedesktop.org/show_bug.cgi?id=93746>
>>
>> v2: Skip wait immediately if !radeon_crtc->enabled, as
>>     suggested by Michel.
>>
>> Reported-by: Bernd Steinhauser <linux@xxxxxxxxxxxxxxxxxxxx>
>> Signed-off-by: Mario Kleiner <mario.kleiner.de@xxxxxxxxx>
>> Tested-by: Bernd Steinhauser <linux@xxxxxxxxxxxxxxxxxxxx>
>>
>> Cc: <stable@xxxxxxxxxxxxxxx> # 4.4+
>
> Both patches are
>
> Reviewed-by: Michel Dänzer <michel.daenzer@xxxxxxx>


Applied.  Thanks!

Alex
_______________________________________________
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