-
Notifications
You must be signed in to change notification settings - Fork 5.2k
vc4 drm planes should not define all CRTCs as possible #3734
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
Comments
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. raspberrypi#3734 Signed-off-by: Dave Stevenson <[email protected]>
You're correct that it is wrong, but the suggested solution isn't going to work. possible_crtcs should be set for the primary and cursor planes via Plane creation order also makes life trickier. #3740 should hopefully fix the issue. |
looks hopeful (I increased the number of overlay planes available to 6 per crtc whilst I was in there) |
If the last columns is |
It is.
|
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. raspberrypi#3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. raspberrypi#3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. raspberrypi#3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. raspberrypi#3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
The driver was assigning all planes to crtcs when actually they're mapped to a specific crtc. Correct the mask. #3734 Signed-off-by: Dave Stevenson <[email protected]>
Patch merged ages ago - closing. |
In the current vc4 driver each CRTC is using 3 planes (one of each type) each created with
possible_crtcs=0xff
That value comes from the 3rd argument of
linux/drivers/gpu/drm/vc4/vc4_firmware_kms.c
Line 759 in cc39f1c
This is incorrect for 2 reasons.
First, some unused bits are sets. This is unexpected and that could potentially confuse some client implementations that rely on the detection of the last possible crtcs.
Second, and this is the most important, having multiple bits means that the client can freely associate each plane to each CRTC. This is clearly not the intention here. For example, I used a modified version of sway/wlroots to assign the 1st crtc to the 2nd cursor plane and the 2nd crtc to the 1st cursor plane. This is supposed to be a PERFECTLY LEGAL interpretation of the DRM api. On my rpi4 with 2 monitors, the result was that my left screen was showing the right screen cursor (and the other way around).
So my advice is to change
vc4_firmware_kms.c
as follow:uint32_t possible_crtcs
tovc4_fkms_plane_init
.0xff
bypossible_crtcs
in the call ofdrm_universal_plane_init
.vc4_fkms_plane_init
, usedrm_crtc_mask(ctrc)
for thepossible_crtrs
argument.See also:
swaywm/wlroots#2333
swaywm/wlroots#1943
The text was updated successfully, but these errors were encountered: