From: Chris Zhong Date: Tue, 2 Aug 2016 01:44:21 +0000 (+0800) Subject: drm/rockchip: dw-mipi: remove mode_valid X-Git-Tag: firefly_0821_release~2028 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=d0879670cfce7b98bb7e8b94b669f04dfd96d415;p=firefly-linux-kernel-4.4.55.git 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 --- diff --git a/drivers/gpu/drm/rockchip/dw-mipi-dsi.c b/drivers/gpu/drm/rockchip/dw-mipi-dsi.c index aff222556345..aac04532bcd6 100644 --- a/drivers/gpu/drm/rockchip/dw-mipi-dsi.c +++ b/drivers/gpu/drm/rockchip/dw-mipi-dsi.c @@ -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[] = {