linux-fbdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Hans de Goede <hdegoede@redhat.com>
To: Daniel Vetter <daniel.vetter@intel.com>,
	Jani Nikula <jani.nikula@linux.intel.com>,
	Sean Paul <seanpaul@chromium.org>,
	David Airlie <airlied@linux.ie>,
	Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Cc: Hans de Goede <hdegoede@redhat.com>,
	linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org,
	Bastien Nocera <hadess@hadess.net>
Subject: [PATCH 0/3] fb/drm: Add support for a panel-orientation connector prop
Date: Fri, 08 Sep 2017 11:54:41 +0000	[thread overview]
Message-ID: <20170908115444.19122-1-hdegoede@redhat.com> (raw)

Hi All,

Some x86 clamshell design devices use portrait tablet LCD panels and a
display engine which cannot (transparently) rotate in hardware, so we
need to rotate things in software / let user space deal with this.

The fbcon code has a set of DMI based quirks to automatically detect
such tablet LCD panels and rotate the fbcon to compensate.

The plan was for userspace (e.g. a Wayland compositor) to simply read
/sys/class/graphics/fbcon/rotate and apply the rotation from there to
the LCD panel to compensate.

However this will not work when an external monitor gets plugged in,
since with fbcon rotation is not per output, so the fbcon quirk code
disables the rotation when an external monitor is present.

Using /sys/class/graphics/fbcon/rotate will not help in that case
since it will indicate no rotation is in use. So instead we are going
to need a drm connecter property for this.

This patch-series introduces such a drm connector properperty, it
consists of 3 patches:

1) Make the fbcon quirk table usable outside of the fbcon code
2) Add drm_connector_create_panel_orientation_property and
   drm_connector_attach_panel_orientation_property functions
3) Hook things up in intel_panel.c

Regards,

Hans


p.s.

Note this series does not yet get the panel orientation from the VBT
on Intel devices. I think that for devices which have the panel
upside-down (rather then rotated 90 degrees) this should work, but
I've an i915 patch series pending which corrects for the upside-down
scanario fully inside the i915 driver hiding the upside-down ness
from userspace (and fbcon) and if that series gets merged then in
the upside-down case the "panel orientation" property should read
"Normal" and not "Upside Down", so I've left out hooking up the VBTs
idea of the panel orientation for now.

Note that we could use the new "panel orientation" property for the
upside-down case too and drop my "[v4] drm/i915: Deal with upside-down
mounted LCD panels" patch:
https://patchwork.freedesktop.org/patch/173781/

That patch is not universally liked anyways, so just dropping it and
using the new prop this series introduces might be best.
 

             reply	other threads:[~2017-09-08 11:54 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-09-08 11:54 Hans de Goede [this message]
2017-09-08 11:54 ` [PATCH 1/3] video: fb: Make fbcon dmi quirks usuable for drm drivers too Hans de Goede
2017-09-08 11:54 ` [PATCH 2/3] drm: Add support for a panel-orientation connector property Hans de Goede
2017-09-08 11:54 ` [PATCH 3/3] drm/i915: Add "panel orientation" property to the panel connector Hans de Goede
2017-09-08 12:05 ` [PATCH 0/3] fb/drm: Add support for a panel-orientation connector prop Daniel Vetter
2017-09-08 15:08   ` Hans de Goede

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=20170908115444.19122-1-hdegoede@redhat.com \
    --to=hdegoede@redhat.com \
    --cc=airlied@linux.ie \
    --cc=b.zolnierkie@samsung.com \
    --cc=daniel.vetter@intel.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=hadess@hadess.net \
    --cc=jani.nikula@linux.intel.com \
    --cc=linux-fbdev@vger.kernel.org \
    --cc=seanpaul@chromium.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;
as well as URLs for NNTP newsgroup(s).