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

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

Merge "msm: mdss: add DSI video test pattern generator API"

parents 5f985fb4 ab2da3ab
Loading
Loading
Loading
Loading
+3 −2
Original line number Original line Diff line number Diff line
/* Copyright (c) 2012-2013, The Linux Foundation. All rights reserved.
/* Copyright (c) 2012-2014, The Linux Foundation. All rights reserved.
 *
 *
 * This program is free software; you can redistribute it and/or modify
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
 * it under the terms of the GNU General Public License version 2 and
@@ -327,7 +327,8 @@ void mdss_dsi_panel_reset(struct mdss_panel_data *pdata, int enable);
void mdss_dsi_phy_disable(struct mdss_dsi_ctrl_pdata *ctrl);
void mdss_dsi_phy_disable(struct mdss_dsi_ctrl_pdata *ctrl);
void mdss_dsi_phy_init(struct mdss_panel_data *pdata);
void mdss_dsi_phy_init(struct mdss_panel_data *pdata);
void mdss_dsi_phy_sw_reset(unsigned char *ctrl_base);
void mdss_dsi_phy_sw_reset(unsigned char *ctrl_base);
void mdss_dsi_cmd_test_pattern(struct mdss_panel_data *pdata);
void mdss_dsi_cmd_test_pattern(struct mdss_dsi_ctrl_pdata *ctrl);
void mdss_dsi_video_test_pattern(struct mdss_dsi_ctrl_pdata *ctrl);
void mdss_dsi_panel_pwm_cfg(struct mdss_dsi_ctrl_pdata *ctrl);
void mdss_dsi_panel_pwm_cfg(struct mdss_dsi_ctrl_pdata *ctrl);


void mdss_dsi_ctrl_init(struct mdss_dsi_ctrl_pdata *ctrl);
void mdss_dsi_ctrl_init(struct mdss_dsi_ctrl_pdata *ctrl);
+18 −12
Original line number Original line Diff line number Diff line
/* Copyright (c) 2012-2013, The Linux Foundation. All rights reserved.
/* Copyright (c) 2012-2014, The Linux Foundation. All rights reserved.
 *
 *
 * This program is free software; you can redistribute it and/or modify
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
 * it under the terms of the GNU General Public License version 2 and
@@ -200,28 +200,34 @@ void mdss_dsi_disable_irq_nosync(struct mdss_dsi_ctrl_pdata *ctrl, u32 term)
	spin_unlock(&ctrl->irq_lock);
	spin_unlock(&ctrl->irq_lock);
}
}


void mdss_dsi_cmd_test_pattern(struct mdss_panel_data *pdata)
void mdss_dsi_video_test_pattern(struct mdss_dsi_ctrl_pdata *ctrl)
{
{
	struct mdss_dsi_ctrl_pdata *ctrl_pdata = NULL;
	int i;
	int i;


	if (pdata == NULL) {
	MIPI_OUTP((ctrl->ctrl_base) + 0x015c, 0x021);
		pr_err("%s: Invalid input data\n", __func__);
	MIPI_OUTP((ctrl->ctrl_base) + 0x0164, 0xff0000); /* red */
		return;
	i = 0;
	while (i++ < 50) {
		MIPI_OUTP((ctrl->ctrl_base) + 0x0180, 0x1);
		/* Add sleep to get ~50 fps frame rate*/
		msleep(20);
	}
	MIPI_OUTP((ctrl->ctrl_base) + 0x015c, 0x0);
}
}


	ctrl_pdata = container_of(pdata, struct mdss_dsi_ctrl_pdata,
void mdss_dsi_cmd_test_pattern(struct mdss_dsi_ctrl_pdata *ctrl)
				panel_data);
{
	int i;


	MIPI_OUTP((ctrl_pdata->ctrl_base) + 0x015c, 0x201);
	MIPI_OUTP((ctrl->ctrl_base) + 0x015c, 0x201);
	MIPI_OUTP((ctrl_pdata->ctrl_base) + 0x016c, 0xff0000); /* red */
	MIPI_OUTP((ctrl->ctrl_base) + 0x016c, 0xff0000); /* red */
	i = 0;
	i = 0;
	while (i++ < 50) {
	while (i++ < 50) {
		MIPI_OUTP((ctrl_pdata->ctrl_base) + 0x0184, 0x1);
		MIPI_OUTP((ctrl->ctrl_base) + 0x0184, 0x1);
		/* Add sleep to get ~50 fps frame rate*/
		/* Add sleep to get ~50 fps frame rate*/
		msleep(20);
		msleep(20);
	}
	}
	MIPI_OUTP((ctrl_pdata->ctrl_base) + 0x015c, 0x0);
	MIPI_OUTP((ctrl->ctrl_base) + 0x015c, 0x0);
}
}


void mdss_dsi_host_init(struct mipi_panel_info *pinfo,
void mdss_dsi_host_init(struct mipi_panel_info *pinfo,