Skip to content

dix: add generic Xinerama capable VRR infrastructure

We don't have a standard protocol for enabling VRR yet, but some time ago an ad-hoc had been made in the amdgpu driver (later also copied to modsetting), which works by client setting the _VARIABLE_REFRESH window property.

The way it's currently done - driver is highjacking the X_ChangeProperty and X_DeleteProperty request handlers - is pretty fragile, and is also a violation of layers: drivers never should be twisted with core protocol details. (And in the future, this should be done by some suitable extension).

Another problem is Xinerama: when it's enabled, this only works on the first screen - the others won't ever see this signal, no matter on which one(s) the Window is physically placed (for the wire protocol, all windows are on screen 0, unless the client explicitly creates them on another one)

This commit adds a generic Screen proc for telling the DDX, whether the VRR mode shall be changed (for now, it's only DISABLED and ENABLED). Drivers can hook into here in order to receive this signal, w/o having to highjack any core request handlers. Catching the property change is now entirely done in the DIX.

The (non-standard) status qou of (ab)using window properties is kept, but it's now also easy to add a new signaling mechanism, in case a standard is agreed on.

Yet a quite naive implementation (eg. not acting on moving windows between screens), but enough to fix the most pressing problems supporting extra screens in general, as well as stopping the highjacking of core request handlers by drivers.

Signed-off-by: Enrico Weigelt, metux IT consult info@metux.net

Merge request reports

Loading