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

Commit 218244e5 authored by Narendra Muppalla's avatar Narendra Muppalla Committed by Gerrit - the friendly Code Review server
Browse files

disp: msm: update rm topology mapping tables



This change updates resource topology mapping tables and includes
logic to compare compression types for dsc vs vdc.

Change-Id: I1735edeb07aec8ed0065f84ac0824c58158412f3
Signed-off-by: default avatarNarendra Muppalla <NarendraM@codeaurora.org>
parent 62cb53cc
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -425,6 +425,7 @@ int dp_connector_get_mode_info(struct drm_connector *connector,
			sizeof(mode_info->comp_info));

		topology->num_enc = topology->num_lm;
		topology->comp_type = mode_info->comp_info.comp_type;
	}

	return 0;
+2 −2
Original line number Diff line number Diff line
@@ -512,14 +512,14 @@ int dsi_conn_get_mode_info(struct drm_connector *connector,
	memcpy(&mode_info->topology, &dsi_mode.priv_info->topology,
			sizeof(struct msm_display_topology));

	mode_info->comp_info.comp_type = MSM_DISPLAY_COMPRESSION_NONE;

	if (dsi_mode.priv_info->dsc_enabled) {
		mode_info->comp_info.comp_type = MSM_DISPLAY_COMPRESSION_DSC;
		mode_info->topology.comp_type = MSM_DISPLAY_COMPRESSION_DSC;
		memcpy(&mode_info->comp_info.dsc_info, &dsi_mode.priv_info->dsc,
			sizeof(dsi_mode.priv_info->dsc));
	} else if (dsi_mode.priv_info->vdc_enabled) {
		mode_info->comp_info.comp_type = MSM_DISPLAY_COMPRESSION_VDC;
		mode_info->topology.comp_type = MSM_DISPLAY_COMPRESSION_VDC;
		memcpy(&mode_info->comp_info.vdc_info, &dsi_mode.priv_info->vdc,
			sizeof(dsi_mode.priv_info->vdc));
	}
+2 −0
Original line number Diff line number Diff line
@@ -645,11 +645,13 @@ struct msm_compression_info {
 * @num_lm:       number of layer mixers used
 * @num_enc:      number of compression encoder blocks used
 * @num_intf:     number of interfaces the panel is mounted on
 * @comp_type:    type of compression supported
 */
struct msm_display_topology {
	u32 num_lm;
	u32 num_enc;
	u32 num_intf;
	enum msm_display_compression_type comp_type;
};

/**
+2 −2
Original line number Diff line number Diff line
@@ -2303,7 +2303,7 @@ static int sde_connector_populate_mode_info(struct drm_connector *conn,
		sde_kms_info_add_keyint(info, "bit_clk_rate",
					mode_info.clk_rate);

		topology_idx = (int)sde_rm_get_topology_name(
		topology_idx = (int)sde_rm_get_topology_name(&sde_kms->rm,
					mode_info.topology);
		if (topology_idx < SDE_RM_TOPOLOGY_MAX) {
			sde_kms_info_add_keystr(info, "topology",
+2 −1
Original line number Diff line number Diff line
@@ -877,7 +877,8 @@ static int _sde_encoder_atomic_check_reserve(struct drm_encoder *drm_enc,
		if (crtc_state->active)
			topology = &sde_conn_state->mode_info.topology;

		ret = sde_rm_update_topology(conn_state, topology);
		ret = sde_rm_update_topology(&sde_kms->rm,
				conn_state, topology);
		if (ret) {
			SDE_ERROR_ENC(sde_enc,
				"RM failed to update topology, rc: %d\n", ret);
Loading