drm/rockchip: dw-mipi: remove mode_valid

The MIPI DSI do not need check the validity of resolution, the max resolution
should depend VOP. So remove rk3288_mipi_dsi_mode_valid here.

Change-Id: I789d184f9a14010795fe595ef31e1bea5d1022e0
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
This commit is contained in:
Chris Zhong 2016-08-02 09:44:21 +08:00 committed by Gerrit Code Review
commit d0879670cf

View file

@ -1107,33 +1107,11 @@ static int rockchip_mipi_parse_dt(struct dw_mipi_dsi *dsi)
return 0;
}
static enum drm_mode_status rk3288_mipi_dsi_mode_valid(
struct drm_connector *connector,
struct drm_display_mode *mode)
{
/*
* The VID_PKT_SIZE field in the DSI_VID_PKT_CFG
* register is 11-bit.
*/
if (mode->hdisplay > 0x7ff)
return MODE_BAD_HVALUE;
/*
* The V_ACTIVE_LINES field in the DSI_VTIMING_CFG
* register is 11-bit.
*/
if (mode->vdisplay > 0x7ff)
return MODE_BAD_VVALUE;
return MODE_OK;
}
static struct dw_mipi_dsi_plat_data rk3288_mipi_dsi_drv_data = {
.dsi0_en_bit = RK3288_DSI0_SEL_VOP_LIT,
.dsi1_en_bit = RK3288_DSI1_SEL_VOP_LIT,
.grf_switch_reg = RK3288_GRF_SOC_CON6,
.max_data_lanes = 4,
.mode_valid = rk3288_mipi_dsi_mode_valid,
};
static struct dw_mipi_dsi_plat_data rk3399_mipi_dsi_drv_data = {
@ -1143,7 +1121,6 @@ static struct dw_mipi_dsi_plat_data rk3399_mipi_dsi_drv_data = {
.grf_dsi0_mode = RK3399_GRF_DSI_MODE,
.grf_dsi0_mode_reg = RK3399_GRF_SOC_CON22,
.max_data_lanes = 4,
.mode_valid = rk3288_mipi_dsi_mode_valid,
};
static const struct of_device_id dw_mipi_dsi_dt_ids[] = {