From: Thomas Zimmermann <tzimmermann@suse.de>
To: airlied@redhat.com, daniel@ffwll.ch, sam@ravnborg.org,
kraxel@redhat.com, emil.l.velikov@gmail.com
Cc: Thomas Zimmermann <tzimmermann@suse.de>, dri-devel@lists.freedesktop.org
Subject: [PATCH 0/3] drm/ast: Disable HW cursor when switching modes
Date: Mon, 27 Jul 2020 09:37:04 +0200 [thread overview]
Message-ID: <20200727073707.21097-1-tzimmermann@suse.de> (raw)
Since converting the ast driver to atomic modesettting, modesetting
occationally locks up the graphics hardware and turns the display
permanently dark. This happens once or twice per 10 modeswitches.
Investigation shows that the ast hardware presumably requires the HW
cursor to be disabled while the modeswitch takes place.
This patchset fixes the problem by disabling the HW cursor before
programming the CRTC mode. After changing the mode, the HW cursor gets
re-enabled if it was enabled before.
Patches #1 and #2 simplify the modesetting and cursor code in preparation
of the actual fix. Patch #3 adds the workaround. The CRTC's atomic_begin()
helper disables an active HW cursor and atomic_flush() re-enables it. The
process is transparent for userspace and the rest of the DRM code. For mere
pageflip operations, nothing changes.
Tested on AST2100 HW. The issue is not 100% reproducible, but does not
show up after applying the patchset. I think the problem has been fixed.
Thomas Zimmermann (3):
drm/ast: Do full modeset if the primary plane's format changes
drm/ast: Store image size in HW cursor info
drm/ast: Disable cursor while switching display modes
drivers/gpu/drm/ast/ast_cursor.c | 13 ++++-
drivers/gpu/drm/ast/ast_drv.h | 9 +++-
drivers/gpu/drm/ast/ast_mode.c | 82 ++++++++++++++++++++++++++------
3 files changed, 86 insertions(+), 18 deletions(-)
--
2.27.0
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
next reply other threads:[~2020-07-27 7:37 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-27 7:37 Thomas Zimmermann [this message]
2020-07-27 7:37 ` [PATCH 1/3] drm/ast: Do full modeset if the primary plane's format changes Thomas Zimmermann
2020-07-27 10:40 ` daniel
2020-07-27 11:24 ` Thomas Zimmermann
2020-07-27 18:31 ` Daniel Vetter
2020-07-27 7:37 ` [PATCH 2/3] drm/ast: Store image size in HW cursor info Thomas Zimmermann
2020-07-27 10:42 ` daniel
2020-07-27 11:37 ` Thomas Zimmermann
2020-07-27 18:32 ` Daniel Vetter
2020-07-27 7:37 ` [PATCH 3/3] drm/ast: Disable cursor while switching display modes Thomas Zimmermann
2020-07-27 10:46 ` daniel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200727073707.21097-1-tzimmermann@suse.de \
--to=tzimmermann@suse.de \
--cc=airlied@redhat.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=emil.l.velikov@gmail.com \
--cc=kraxel@redhat.com \
--cc=sam@ravnborg.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox