dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
To: dri-devel@lists.freedesktop.org
Cc: "Cc : Daniel Stone" <daniels@collabora.com>
Subject: [PATCH 0/2] Add support for passing crtc_id to page flip events.
Date: Wed, 10 Aug 2016 12:46:22 +0200	[thread overview]
Message-ID: <1470825984-9441-1-git-send-email-maarten.lankhorst@linux.intel.com> (raw)

When generating events for a atomic commit involving multiple crtc's
it's not possible to distinguish which crtc belongs to which page flip event.
Solve this by putting crtc_id in the reserved member of page_flip_event.

I've checked weston, and the following ddx: modesetting (xserver), i915,
nouveau, ati, vmwgfx.

None of them depend in any way on the reserved member, so setting it to
non-zero should be safe. A lot of them use libdrm, which hides the page
flip event struct and only passes its members.

This is why I also changed libdrm to pass crtc_id in page_flip_handler2.
Any compositor that uses drmHandleEvent will be able to get information
about the crtc_id too, if available.

Maarten Lankhorst (2):
  (kernel) drm/core: Reuse the reserved member in drm_event_vblank for crtc_id.
  (libdrm) Add support for crtc_id in page flip events

Kernel:
 drivers/gpu/drm/drm_irq.c | 2 ++
 include/uapi/drm/drm.h    | 2 +-
 2 files changed, 3 insertions(+), 1 deletion(-)

Libdrm:
 include/drm/drm.h         |  2 +-
 tests/modetest/modetest.c | 20 ++++++++++++++++++--
 xf86drm.h                 | 16 +++++++++++++++-
 xf86drmMode.c             | 23 ++++++++++++++++-------
 4 files changed, 50 insertions(+), 11 deletions(-)
-- 
2.7.4

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

             reply	other threads:[~2016-08-10 10:46 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-10 10:46 Maarten Lankhorst [this message]
2016-08-10 10:46 ` [PATCH 1/2] drm/core: Reuse the reserved member in drm_event_vblank for crtc_id Maarten Lankhorst
2016-08-10 14:14   ` Daniel Vetter
2016-10-19  9:41     ` Maarten Lankhorst
2016-08-10 10:46 ` [LIBDRM PATCH 2/2] Add support for crtc_id in page flip events Maarten Lankhorst

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=1470825984-9441-1-git-send-email-maarten.lankhorst@linux.intel.com \
    --to=maarten.lankhorst@linux.intel.com \
    --cc=daniels@collabora.com \
    --cc=dri-devel@lists.freedesktop.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