summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/rockchip/dw-mipi-dsi.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/drm/rockchip/dw-mipi-dsi.c')
-rw-r--r--drivers/gpu/drm/rockchip/dw-mipi-dsi.c20
1 files changed, 18 insertions, 2 deletions
diff --git a/drivers/gpu/drm/rockchip/dw-mipi-dsi.c b/drivers/gpu/drm/rockchip/dw-mipi-dsi.c
index 38e4811be728..c5dc3766e932 100644
--- a/drivers/gpu/drm/rockchip/dw-mipi-dsi.c
+++ b/drivers/gpu/drm/rockchip/dw-mipi-dsi.c
@@ -1094,6 +1094,8 @@ static struct drm_connector_funcs dw_mipi_dsi_atomic_connector_funcs = {
.atomic_destroy_state = drm_atomic_helper_connector_destroy_state,
};
+static int deferred_cnt = 0;
+
static int dw_mipi_dsi_register(struct drm_device *drm,
struct dw_mipi_dsi *dsi)
{
@@ -1110,8 +1112,15 @@ static int dw_mipi_dsi_register(struct drm_device *drm,
* not been registered yet. Defer probing, and hope that
* the required CRTC is added later.
*/
- if (encoder->possible_crtcs == 0)
+ if (encoder->possible_crtcs == 0) {
+ if ( deferred_cnt > 10 ) {
+ printk(KERN_ERR "%s:%d: !possible_crtcs: returning ENODEV\n", __FUNCTION__, __LINE__);
+ return -ENODEV;
+ }
+ deferred_cnt++;
+ printk(KERN_INFO "%s:%d: !possible_crtcs: returning EPROBE_DEFER #%d\n", __FUNCTION__, __LINE__, deferred_cnt++);
return -EPROBE_DEFER;
+ }
drm_encoder_helper_add(&dsi->encoder,
&dw_mipi_dsi_encoder_helper_funcs);
@@ -1200,8 +1209,15 @@ static int dw_mipi_dsi_bind(struct device *dev, struct device *master,
struct resource *res;
int ret;
- if (!dsi->panel)
+ if (!dsi->panel) {
+ if ( deferred_cnt > 10 ) {
+ printk(KERN_ERR "%s:%d: !panel: returning ENODEV\n", __FUNCTION__, __LINE__);
+ return -ENODEV;
+ }
+ deferred_cnt++;
+ printk(KERN_INFO "%s:%d: !panel: returning EPROBE_DEFER #%d\n", __FUNCTION__, __LINE__, deferred_cnt);
return -EPROBE_DEFER;
+ }
ret = rockchip_mipi_parse_dt(dsi);
if (ret)