]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
drm/simpledrm: Add "panel orientation" property on non-upright mounted LCD panels
authorHans de Goede <hdegoede@redhat.com>
Mon, 21 Feb 2022 22:00:45 +0000 (23:00 +0100)
committerStefan Bader <stefan.bader@canonical.com>
Fri, 20 May 2022 12:37:35 +0000 (14:37 +0200)
commitf2d2ad27b9aba9643c592cec45ff9297a4cc89c2
tree84d5d58fa0823adbf10ea973d2487d0afb9861ef
parentc07579e25ea211f949d691f18222a2ea6ce7f649
drm/simpledrm: Add "panel orientation" property on non-upright mounted LCD panels

BugLink: https://bugs.launchpad.net/bugs/1969110
commit 94fa115f7b28a3f02611499175e134f0a823b686 upstream.

Some devices use e.g. a portrait panel in a standard laptop casing made
for landscape panels. efifb calls drm_get_panel_orientation_quirk() and
sets fb_info.fbcon_rotate_hint to make fbcon rotate the console so that
it shows up-right instead of on its side.

When switching to simpledrm the fbcon renders on its side. Call the
drm_connector_set_panel_orientation_with_quirk() helper to add
a "panel orientation" property on devices listed in the quirk table,
to make the fbcon (and aware userspace apps) rotate the image to
display properly.

Cc: Javier Martinez Canillas <javierm@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>
Acked-by: Thomas Zimmermann <tzimmermann@suse.de>
Link: https://patchwork.freedesktop.org/patch/msgid/20220221220045.11958-1-hdegoede@redhat.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit 476df59948786dabbd84c53d233081c36982a7d7)
Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
drivers/gpu/drm/tiny/simpledrm.c