From: Ivan Mironov <mironov.ivan@gmail.com>
To: dri-devel@lists.freedesktop.org
Cc: linux-kernel@vger.kernel.org,
Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
Maxime Ripard <maxime.ripard@bootlin.com>,
Sean Paul <sean@poorly.run>, David Airlie <airlied@linux.ie>,
Daniel Vetter <daniel@ffwll.ch>, saahriktu <mail@saahriktu.org>,
Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>,
Ivan Mironov <mironov.ivan@gmail.com>
Subject: [RFC PATCH 0/2] Fix SDL 1.2 on emulated fbdev devices (broken in kernels >=4.19)
Date: Wed, 26 Dec 2018 17:11:22 +0500 [thread overview]
Message-ID: <20181226121124.1632-1-mironov.ivan@gmail.com> (raw)
Hi,
Originally this issue was brought up on linux.org.ru forum by user
saahriktu, he is on Cc. He discovered that commit db05c48197759
("drm: fb-helper: Reject all pixel format changing requests") breaks
support of SDL1 programs, like various old games and emulators of old
game consoles. First patch contains fix for that commit.
I tried to reproduce the same issue in a VM under qemu, and found yet
another part of kernel code which prevents SDL1 apps from running
normally. Second patch in this series fixes this problem.
However, I still have few unresolved questions regarding this patches:
* Why simple revert of commit db05c48197759 fixes SDL1 support for
saahriktu? I do not understand how this could work when SDL1 has
hardcoded non-zero pixclock values, for which current code always
returns EINVAL.
* How this worked before? How this is working for non-DRM fbdev drivers?
fbdev support code in SDL1 is also very old by the way.
Also, it seems that at least in some cases both problems could be
circumvented by adding appropriate modes into /etc/fb.modes. But without
examining the kernel code it is not clear which values are correct. I am
not sure that such circumvention covers all possible cases, and it is
definitely far from any user-frienliness.
Ah, almost forgot this: the easiest way to reproduce both problems is to
install sdl-sopwith[1] and try to run it from console without X. At
least in Fedora 29, sopwith may be simply installed from standard
repositories.
[1] http://sdl-sopwith.sourceforge.net/
Ivan Mironov (2):
drm/fb-helper: Bring back workaround for bugs of SDL 1.2
drm/fb-helper: Ignore the value of fb_var_screeninfo.pixclock
drivers/gpu/drm/drm_fb_helper.c | 153 +++++++++++++++++++++-----------
1 file changed, 99 insertions(+), 54 deletions(-)
--
2.20.1
next reply other threads:[~2018-12-26 12:11 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-26 12:11 Ivan Mironov [this message]
2018-12-26 12:11 ` [RFC PATCH 1/2] drm/fb-helper: Bring back workaround for bugs of SDL 1.2 Ivan Mironov
2018-12-27 12:00 ` Daniel Vetter
2018-12-27 12:00 ` Daniel Vetter
2018-12-27 23:26 ` Ivan Mironov
2018-12-28 12:02 ` Daniel Vetter
2018-12-26 12:11 ` [RFC PATCH 2/2] drm/fb-helper: Ignore the value of fb_var_screeninfo.pixclock Ivan Mironov
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=20181226121124.1632-1-mironov.ivan@gmail.com \
--to=mironov.ivan@gmail.com \
--cc=Eugeniy.Paltsev@synopsys.com \
--cc=airlied@linux.ie \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-kernel@vger.kernel.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mail@saahriktu.org \
--cc=maxime.ripard@bootlin.com \
--cc=sean@poorly.run \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.