Commit 8a170832 authored by Alex Hung's avatar Alex Hung Committed by Alex Deucher
Browse files

drm/amd/display: Remove redundant checks for opp



The null checks for opp are redundant as they were already
dereferenced previously, as reported by Coverity; therefore
the null checks are removed.

This fixes 2 REVERSE_INULL issues reported by Coverity.

Reviewed-by: default avatarHarry Wentland <harry.wentland@amd.com>
Acked-by: default avatarHamza Mahfooz <hamza.mahfooz@amd.com>
Signed-off-by: default avatarAlex Hung <alex.hung@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 14f293e0
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1260,7 +1260,7 @@ void dcn10_plane_atomic_disconnect(struct dc *dc,
	mpc->funcs->remove_mpcc(mpc, mpc_tree_params, mpcc_to_remove);
	// Phantom pipes have OTG disabled by default, so MPCC_STATUS will never assert idle,
	// so don't wait for MPCC_IDLE in the programming sequence
	if (opp != NULL && dc_state_get_pipe_subvp_type(state, pipe_ctx) != SUBVP_PHANTOM)
	if (dc_state_get_pipe_subvp_type(state, pipe_ctx) != SUBVP_PHANTOM)
		opp->mpcc_disconnect_pending[pipe_ctx->plane_res.mpcc_inst] = true;

	dc->optimized_required = true;
+1 −2
Original line number Diff line number Diff line
@@ -408,7 +408,6 @@ void dcn201_plane_atomic_disconnect(struct dc *dc,
	if (mpcc_removed == false)
		return;

	if (opp != NULL)
	opp->mpcc_disconnect_pending[pipe_ctx->plane_res.mpcc_inst] = true;

	dc->optimized_required = true;