[PATCH kernel 1/2] drm: Pass CRTC ID in userspace vblank events

Daniel Stone daniel at fooishbar.org
Tue Apr 4 20:53:46 UTC 2017


Hi,

On 4 April 2017 at 18:58, Sean Paul <seanpaul at chromium.org> wrote:
> On Tue, Apr 04, 2017 at 05:52:21PM +0100, Daniel Stone wrote:
>> With the atomic API, it is possible that a single commit affects
>> multiple crtcs. If the user requests an event with that commit, one
>> event will be sent for each CRTC, but it is not possible to distinguish
>> which crtc an event is for in user space. To solve this, the reserved
>> field in struct drm_vblank_event is repurposed to include the crtc_id
>> which the event is for.
>>
>> The DRM_CAP_CRTC_IN_VBLANK_EVENT is added to allow userspace to query if
>> the crtc field will be set properly.
>>
>> [daniels: Rebased, using Maarten's forward-port.]
>
> Yeah, this seems like good use of the reserved field to me.
>
> Reviewed-by: Sean Paul <seanpaul at chromium.org>

Thanks Sean for the review! I've pushed this to drm-misc-next ...
without your R-b tag, as I botched my first dim. Oops.

libdrm v2 has been sent, and Weston atomic will be revved to use this
with its real version number when that gets merged and released. FWIW,
the Weston side was also acked by Pekka Paalanen, though I'll let him
add his thoughts in his own words tomorrow.

Cheers,
Daniel


More information about the dri-devel mailing list