Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

set supported interface version for wl_output #99

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Kiskae
Copy link

@Kiskae Kiskae commented Aug 9, 2023

Prompted by NixOS/nixpkgs#248119

Recent releases of the wayland protocol updated the wl_output protocol to version 4, which added the wl_output@name opcode. Since the nvidia wayland connector does not check the version it advertises support but does not register the required handler for that opcode, resulting in an abort when the callback is invoked.

This PR is based on a similar problem reported in swaywm/sway#6717 and clamps the version to the supported range.

Output with WAYLAND_DEBUG before change:

[2919666.139] wl_output@4.geometry(0, 0, 620, 340, 0, "BNQ", "BenQ EL2870U", 0)
[2919666.141] wl_output@4.mode(3, 3840, 2160, 59996)
[2919666.142] wl_output@4.scale(2)
[2919666.143] wl_output@4.name("DP-4")
fish: Job 1, 'WAYLAND_DEBUG=1 nvidia-settings' terminated by signal SIGABRT (Abort)

Output after change:

[2872229.841] wl_output@6.geometry(0, 0, 620, 340, 0, "BNQ", "BenQ EL2870U", 0)
[2872229.846] wl_output@6.mode(3, 3840, 2160, 59996)
[2872229.848] wl_output@6.scale(2)
[2872229.849] wl_output@6.done()

@Kiskae
Copy link
Author

Kiskae commented Oct 31, 2023

Appears to be fixed in 545.29.02, leaving it open since the production branch is still affected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant