Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Register
  • Sign in
  • D drm-hwcomposer
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 13
    • Issues 13
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 4
    • Merge requests 4
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • drm-hwcomposer
  • drm-hwcomposer
  • Merge requests
  • !135

drm_hwcomposer: Fix drmSetMaster() usage

  • Review changes

  • Download
  • Patches
  • Plain diff
Merged John Stultz requested to merge john.stultz/drm-hwcomposer:fix-for-5.4-kernels into main Feb 02, 2021
  • Overview 10
  • Commits 1
  • Pipelines 2
  • Changes 1

After commit 3b24cd91 ("drm_hwcomposer: Ensure composer has master access to DRM/KMS") was merged I started seeing failures on 5.4 based kernels.

Diggin into it, it seemed on those kernels drmSetMaster() was always returning -EACCES, due to the following upstream kernel change not being present: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=45bc3d26c95a8fc63a7d8668ca9e57ef0883351c

That change landed around 5.6, so for older kernels we need to make sure older kernels without this patch still work. So this patch, as suggested by Roman Stratiienko, reworks the logic so we call drmSetMaster() and then check drmIsMaster(), rather then failing due to the return value.

With this patch, things are back to working on both hikey960 and db845c with 5.4 based kernels. Signed-off-by: John Stultz john.stultz@linaro.org Change-Id: I7f2adba3ddbd36169b6d26baf49299046efcf906

Edited Feb 12, 2021 by John Stultz
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: fix-for-5.4-kernels