drm/amd/display: Keep linebuffer pixel depth at 30bpp for DCE-11.0.
Subsystems (3)
PATCH 1/1 drm/amd/display: Keep linebuffer pixel depth at 30bpp for DCE-11.0.
Testing on AMD Carizzo with DCE-11.0 display engine showed that it doesn't like a 36 bpp linebuffer very much. The display just showed a solid green.
Testing on RavenRidge DCN-1.0, Polaris11 with DCE-11.2 and Kabini with DCE-8.3 did not expose any problems, so for now only revert to 30 bpp linebuffer depth on asics with DCE-11.0 display engine.
--- drivers/gpu/drm/amd/display/dc/core/dc_resource.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-)
drivers/gpu/drm/amd/display/dc/core/dc_resource.c +9 -2
@@ -1213,9 +1213,16 @@ bool resource_build_scaling_params(struct pipe_ctx *pipe_ctx)* on certain displays, such as the Sharp 4k. 36bpp is needed * to support SURFACE_PIXEL_FORMAT_GRPH_ARGB16161616 and * SURFACE_PIXEL_FORMAT_GRPH_ABGR16161616 with actual > 10 bpc -* precision on at least DCN display engines. +* precision on at least DCN display engines. However, at least +* Carrizo with DCE_VERSION_11_0 does not like 36 bpp lb depth, +* so use only 30 bpp on DCE_VERSION_11_0. Testing with DCE 11.2 and 8.3 +* did not show such problems, so this seems to be the exception. */ - pipe_ctx->plane_res.scl_data.lb_params.depth =LB_PIXEL_DEPTH_36BPP ; +if (plane_state->ctx->dce_version !=DCE_VERSION_11_0 ) + pipe_ctx->plane_res.scl_data.lb_params.depth =LB_PIXEL_DEPTH_36BPP ; +else + pipe_ctx->plane_res.scl_data.lb_params.depth =LB_PIXEL_DEPTH_30BPP ; + pipe_ctx->plane_res.scl_data.lb_params.alpha_en = plane_state->per_pixel_alpha; pipe_ctx->plane_res.scl_data.recout.x += timing->h_border_left;
Signature · 6 lines
2.25.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Quoted 11 lines · Mario Kleiner
Testing on AMD Carizzo with DCE-11.0 display engine showed that it doesn't like a 36 bpp linebuffer very much. The display just showed a solid green.
Testing on RavenRidge DCN-1.0, Polaris11 with DCE-11.2 and Kabini with DCE-8.3 did not expose any problems, so for now only revert to 30 bpp linebuffer depth on asics with DCE-11.0 display engine.
Reported-by Tom StDenis <[email protected]>Signed-off-by Mario Kleiner <[email protected]>Cc Alex Deucher <[email protected]>
Curious now why Carrizo doesn't like a LB depth of 36bpp but this should fix the issue.
Harry
Quoted 18 lines
--- drivers/gpu/drm/amd/display/dc/core/dc_resource.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-)drivers/gpu/drm/amd/display/dc/core/dc_resource.c +4
-1@@ -1213,9 +1213,16 @@ bool resource_build_scaling_params(struct pipe_ctx *pipe_ctx)* on certain displays, such as the Sharp 4k. 36bpp is needed * to support SURFACE_PIXEL_FORMAT_GRPH_ARGB16161616 and * SURFACE_PIXEL_FORMAT_GRPH_ABGR16161616 with actual > 10 bpc -* precision on at least DCN display engines. +* precision on at least DCN display engines. However, at least +* Carrizo with DCE_VERSION_11_0 does not like 36 bpp lb depth, +* so use only 30 bpp on DCE_VERSION_11_0. Testing with DCE 11.2 and 8.3 +* did not show such problems, so this seems to be the exception.
drivers/gpu/drm/amd/display/dc/core/dc_resource.c bool resource_build_scaling_params(struct pipe_ctx *pipe_ctx) · line 1228
Quoted 10 lines
drivers/gpu/drm/amd/display/dc/core/dc_resource.c +5
-1*/ - pipe_ctx->plane_res.scl_data.lb_params.depth =LB_PIXEL_DEPTH_36BPP ; +if (plane_state->ctx->dce_version !=DCE_VERSION_11_0 ) + pipe_ctx->plane_res.scl_data.lb_params.depth =LB_PIXEL_DEPTH_36BPP ; +else + pipe_ctx->plane_res.scl_data.lb_params.depth =LB_PIXEL_DEPTH_30BPP ; + pipe_ctx->plane_res.scl_data.lb_params.alpha_en = plane_state->per_pixel_alpha; pipe_ctx->plane_res.scl_data.recout.x += timing->h_border_left;
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Alex Deucher
AppliedApplied. Thanks!
Alex
Quoted 47 lines · Harry Wentland
Quoted 11 lines · Mario Kleiner
Testing on AMD Carizzo with DCE-11.0 display engine showed that it doesn't like a 36 bpp linebuffer very much. The display just showed a solid green.
Testing on RavenRidge DCN-1.0, Polaris11 with DCE-11.2 and Kabini with DCE-8.3 did not expose any problems, so for now only revert to 30 bpp linebuffer depth on asics with DCE-11.0 display engine.
Reported-by Tom StDenis <[email protected]>Signed-off-by Mario Kleiner <[email protected]>Cc Alex Deucher <[email protected]>Curious now why Carrizo doesn't like a LB depth of 36bpp but this should fix the issue.
Reviewed-by Harry Wentland <[email protected]>Harry
Quoted 26 lines
--- drivers/gpu/drm/amd/display/dc/core/dc_resource.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-)drivers/gpu/drm/amd/display/dc/core/dc_resource.c +9
-2@@ -1213,9 +1213,16 @@ bool resource_build_scaling_params(struct pipe_ctx *pipe_ctx)* on certain displays, such as the Sharp 4k. 36bpp is needed * to support SURFACE_PIXEL_FORMAT_GRPH_ARGB16161616 and * SURFACE_PIXEL_FORMAT_GRPH_ABGR16161616 with actual > 10 bpc -* precision on at least DCN display engines. +* precision on at least DCN display engines. However, at least +* Carrizo with DCE_VERSION_11_0 does not like 36 bpp lb depth, +* so use only 30 bpp on DCE_VERSION_11_0. Testing with DCE 11.2 and 8.3 +* did not show such problems, so this seems to be the exception. */ - pipe_ctx->plane_res.scl_data.lb_params.depth =LB_PIXEL_DEPTH_36BPP ; +if (plane_state->ctx->dce_version !=DCE_VERSION_11_0 ) + pipe_ctx->plane_res.scl_data.lb_params.depth =LB_PIXEL_DEPTH_36BPP ; +else + pipe_ctx->plane_res.scl_data.lb_params.depth =LB_PIXEL_DEPTH_30BPP ; + pipe_ctx->plane_res.scl_data.lb_params.alpha_en = plane_state->per_pixel_alpha;
Quoted 7 lines
drivers/gpu/drm/amd/display/dc/core/dc_resource.c bool resource_build_scaling_params(struct pipe_ctx *pipe_ctx) · line 1228
Quoted 2 lines
drivers/gpu/drm/amd/display/dc/core/dc_resource.c +0
-0pipe_ctx->plane_res.scl_data.recout.x += timing->h_border_left;_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx