Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a6c09b6f authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "disp: msm: sde: fix null check for encoder dsc disable"

parents db766d7c 8dd8a0f1
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -691,13 +691,19 @@ static void _dce_dsc_disable(struct sde_encoder_virt *sde_enc)
	struct sde_hw_ctl *hw_ctl = NULL;
	struct sde_hw_intf_cfg_v1 cfg;

	if (!sde_enc || !sde_enc->phys_encs[0] ||
			!sde_enc->phys_encs[0]->connector) {
	if (!sde_enc || !sde_enc->phys_encs[0]) {
		SDE_ERROR("invalid params %d %d\n",
			!sde_enc, sde_enc ? !sde_enc->phys_encs[0] : -1);
		return;
	}

	/*
	 * Connector can be null if the first virt modeset after suspend
	 * is called with dynamic clock or dms enabled.
	 */
	if (!sde_enc->phys_encs[0]->connector)
		return;

	if (sde_enc->cur_master)
		hw_ctl = sde_enc->cur_master->hw_ctl;