Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Register
  • Sign in
  • phosh phosh
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Graph
    • Compare
  • Issues 234
    • Issues 234
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 29
    • Merge requests 29
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Container Registry
    • Infrastructure Registry
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • World
  • Phosh
  • phoshphosh
  • Merge requests
  • !1186

Use memfd for shm buffers

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Guido Günther requested to merge guidog/phosh:use-memfd into main Jan 05, 2023
  • Overview 6
  • Commits 4
  • Pipelines 6
  • Changes 4

Wanted to do this a while back but completely forgot.

This makes shm handling simpler as the compositor doesn't have to worry about the SIGBUS handler.

See sigbus_is_impossible in https://gitlab.freedesktop.org/wayland/wayland/-/blob/main/src/wayland-shm.c#L325

This would have avoided phoc#290 (closed) as well (but it's good to have that sorted on the compositor side so clients can't trigger it). https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/474 is a good reference.

I added a warning for linux without memfd_create.

I got reminded of this by https://lwn.net/Articles/918106/

Edited Jan 15, 2023 by Guido Günther
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: use-memfd