Skip to content
Snippets Groups Projects

xf86drmMode: add drmIsKMS

Merged Simon Ser requested to merge emersion/drm:is-kms into master

If a device has a primary node, it doesn't necessarily mean it's suitable for KMS usage. For instance, render-only drivers also expose primary nodes.

The check is extracted from Weston 1.

The motivation for this new function is two-fold:

  • Avoid an unnecessary GETRESOURCES call. To check whether a primary node is suitable for KMS, we don't actually need to retrieve the object IDs we just need to check the counts.
  • Avoid confusion in user-space and make sure user-space implements the check properly. For instance, wlroots doesn't 2: it uses drmGetVersion which succeeds with render-only drivers.

Signed-off-by: Simon Ser contact@emersion.fr

cc @pq @danvet @evelikov

Edited by Simon Ser

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
Please register or sign in to reply
Loading