drm/radeon/kms: allow "invalid" DB formats as a means to disable DB
Signed-off-by: Marek Olšák <maraeo@gmail.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
@@ -961,13 +961,15 @@ static int evergreen_cs_track_check(struct radeon_cs_parser *p)
|
||||
|
||||
if (track->db_dirty) {
|
||||
/* Check stencil buffer */
|
||||
if (G_028800_STENCIL_ENABLE(track->db_depth_control)) {
|
||||
if (G_028044_FORMAT(track->db_s_info) != V_028044_STENCIL_INVALID &&
|
||||
G_028800_STENCIL_ENABLE(track->db_depth_control)) {
|
||||
r = evergreen_cs_track_validate_stencil(p);
|
||||
if (r)
|
||||
return r;
|
||||
}
|
||||
/* Check depth buffer */
|
||||
if (G_028800_Z_ENABLE(track->db_depth_control)) {
|
||||
if (G_028040_FORMAT(track->db_z_info) != V_028040_Z_INVALID &&
|
||||
G_028800_Z_ENABLE(track->db_depth_control)) {
|
||||
r = evergreen_cs_track_validate_depth(p);
|
||||
if (r)
|
||||
return r;
|
||||
|
Reference in New Issue
Block a user