]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commit
drm/tve200: Stabilize enable/disable
authorLinus Walleij <linus.walleij@linaro.org>
Thu, 20 Aug 2020 20:31:44 +0000 (22:31 +0200)
committerStefan Bader <stefan.bader@canonical.com>
Mon, 9 Nov 2020 13:46:48 +0000 (14:46 +0100)
commita135ba0b285c020a07ae00cab3b3bccd6bcd62bc
tree0e9c305aebbc5382279f3f751c4d2c37f11db3bb
parent221794a28d4b9fa7b6816a1d66e3cd703cb5834b
drm/tve200: Stabilize enable/disable

BugLink: https://bugs.launchpad.net/bugs/1896824
commit f71800228dc74711c3df43854ce7089562a3bc2d upstream.

The TVE200 will occasionally print a bunch of lost interrupts
and similar dmesg messages, sometimes during boot and sometimes
after disabling and coming back to enablement. This is probably
because the hardware is left in an unknown state by the boot
loader that displays a logo.

This can be fixed by bringing the controller into a known state
by resetting the controller while enabling it. We retry reset 5
times like the vendor driver does. We also put the controller
into reset before de-clocking it and clear all interrupts before
enabling the vblank IRQ.

This makes the video enable/disable/enable cycle rock solid
on the D-Link DIR-685. Tested extensively.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: stable@vger.kernel.org
Link: https://patchwork.freedesktop.org/patch/msgid/20200820203144.271081-1-linus.walleij@linaro.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: William Breathitt Gray <william.gray@canonical.com>
drivers/gpu/drm/tve200/tve200_display.c