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

Commit 0c4392ea authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "drm/msm/dsi-staging: add qsync/avr support in dsi controller" into dev/msm-4.14-display

parents 7e9d84e2 44576a0a
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -69,6 +69,7 @@ static void dsi_catalog_cmn_init(struct dsi_ctrl_hw *ctrl,
	ctrl->ops.get_hw_version = dsi_ctrl_hw_cmn_get_hw_version;
	ctrl->ops.wait_for_cmd_mode_mdp_idle =
		dsi_ctrl_hw_cmn_wait_for_cmd_mode_mdp_idle;
	ctrl->ops.setup_avr = dsi_ctrl_hw_cmn_setup_avr;

	switch (version) {
	case DSI_CTRL_VERSION_1_4:
+3 −0
Original line number Diff line number Diff line
@@ -151,6 +151,9 @@ void dsi_ctrl_hw_cmn_video_engine_en(struct dsi_ctrl_hw *ctrl, bool on);
void dsi_ctrl_hw_cmn_video_engine_setup(struct dsi_ctrl_hw *ctrl,
				       struct dsi_host_common_cfg *common_cfg,
				       struct dsi_video_engine_cfg *cfg);

void dsi_ctrl_hw_cmn_setup_avr(struct dsi_ctrl_hw *ctrl, bool enable);

void dsi_ctrl_hw_cmn_set_video_timing(struct dsi_ctrl_hw *ctrl,
			 struct dsi_mode_info *mode);
void dsi_ctrl_hw_cmn_set_timing_db(struct dsi_ctrl_hw *ctrl,
+14 −0
Original line number Diff line number Diff line
@@ -2724,6 +2724,20 @@ int dsi_ctrl_vid_engine_en(struct dsi_ctrl *dsi_ctrl, bool on)
	return rc;
}

int dsi_ctrl_setup_avr(struct dsi_ctrl *dsi_ctrl, bool enable)
{
	if (!dsi_ctrl)
		return -EINVAL;

	if (dsi_ctrl->host_config.panel_mode == DSI_OP_VIDEO_MODE) {
		mutex_lock(&dsi_ctrl->ctrl_lock);
		dsi_ctrl->hw.ops.setup_avr(&dsi_ctrl->hw, enable);
		mutex_unlock(&dsi_ctrl->ctrl_lock);
	}

	return 0;
}

/**
 * dsi_ctrl_host_deinit() - De-Initialize DSI host hardware.
 * @dsi_ctrl:        DSI controller handle.
+7 −0
Original line number Diff line number Diff line
@@ -713,6 +713,13 @@ int dsi_ctrl_get_hw_version(struct dsi_ctrl *dsi_ctrl);
 */
int dsi_ctrl_vid_engine_en(struct dsi_ctrl *dsi_ctrl, bool on);

/**
 * dsi_ctrl_setup_avr() - Set/Clear the AVR_SUPPORT_ENABLE bit
 * @dsi_ctrl:        DSI controller handle.
 * @enable:          variable to control AVR support ON/OFF.
 */
int dsi_ctrl_setup_avr(struct dsi_ctrl *dsi_ctrl, bool enable);

/**
 * @dsi_ctrl:        DSI controller handle.
 * cmd_len:	     Length of command.
+7 −0
Original line number Diff line number Diff line
@@ -386,6 +386,13 @@ struct dsi_ctrl_hw_ops {
	 */
	void (*video_engine_en)(struct dsi_ctrl_hw *ctrl, bool on);

	/**
	 * setup_avr() - set the AVR_SUPPORT_ENABLE bit in DSI_VIDEO_MODE_CTRL
	 * @ctrl:	   Pointer to controller host hardware.
	 * @enable:	   Controls whether this bit is set or cleared
	 */
	void (*setup_avr)(struct dsi_ctrl_hw *ctrl, bool enable);

	/**
	 * video_engine_setup() - Setup dsi host controller for video mode
	 * @ctrl:          Pointer to controller host hardware.
Loading