aboutsummaryrefslogtreecommitdiffstats
path: root/include/drm/drm_crtc.h
diff options
context:
space:
mode:
authorRob Clark <rob@ti.com>2012-09-04 12:35:56 -0400
committerDave Airlie <airlied@redhat.com>2012-10-02 08:16:07 -0400
commit7c80e128429d639742043f8fbdd7f1551c940ea3 (patch)
treed387994498a91a65785ab7e0e559531c45395323 /include/drm/drm_crtc.h
parentf7eff60ea0e4e35732604e3591e2ff7b3ef41981 (diff)
drm: support for rotated scanout
For drivers that can support rotated scanout, the extra parameter checking in drm-core, while nice, tends to get confused. To solve this drivers can set the crtc or plane invert_dimensions field so that the dimension checking takes into account the rotation that the driver is performing. v1: original v2: remove invert_dimensions from plane, at Ville's suggestion. Userspace can give rotated src coordinates, so invert_dimensions is not required for planes. Signed-off-by: Rob Clark <rob@ti.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'include/drm/drm_crtc.h')
-rw-r--r--include/drm/drm_crtc.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/drm/drm_crtc.h b/include/drm/drm_crtc.h
index 68fdb299e39f..8e405b82707d 100644
--- a/include/drm/drm_crtc.h
+++ b/include/drm/drm_crtc.h
@@ -368,6 +368,9 @@ struct drm_crtc_funcs {
368 * @enabled: is this CRTC enabled? 368 * @enabled: is this CRTC enabled?
369 * @mode: current mode timings 369 * @mode: current mode timings
370 * @hwmode: mode timings as programmed to hw regs 370 * @hwmode: mode timings as programmed to hw regs
371 * @invert_dimensions: for purposes of error checking crtc vs fb sizes,
372 * invert the width/height of the crtc. This is used if the driver
373 * is performing 90 or 270 degree rotated scanout
371 * @x: x position on screen 374 * @x: x position on screen
372 * @y: y position on screen 375 * @y: y position on screen
373 * @funcs: CRTC control functions 376 * @funcs: CRTC control functions
@@ -401,6 +404,8 @@ struct drm_crtc {
401 */ 404 */
402 struct drm_display_mode hwmode; 405 struct drm_display_mode hwmode;
403 406
407 bool invert_dimensions;
408
404 int x, y; 409 int x, y;
405 const struct drm_crtc_funcs *funcs; 410 const struct drm_crtc_funcs *funcs;
406 411