drm/tilcdc: tfp410: Set crtc panel info at init phase
authorJyri Sarha <jsarha@ti.com>
Wed, 13 Apr 2016 15:59:16 +0000 (18:59 +0300)
committerJyri Sarha <jsarha@ti.com>
Mon, 8 Aug 2016 20:05:12 +0000 (23:05 +0300)
Set crtc panel info at init phase. Setting it at prepare callback does
it multiple times for no good reason and it is also too late when atomic
modeset is used.

Signed-off-by: Jyri Sarha <jsarha@ti.com>
drivers/gpu/drm/tilcdc/tilcdc_tfp410.c

index 6b8c5b3bf588b01b56a8a398f0f61918507086c3..21f6485c87cb15273b609fdab0e6565b38f889b5 100644 (file)
@@ -75,7 +75,6 @@ static void tfp410_encoder_dpms(struct drm_encoder *encoder, int mode)
 static void tfp410_encoder_prepare(struct drm_encoder *encoder)
 {
        tfp410_encoder_dpms(encoder, DRM_MODE_DPMS_OFF);
-       tilcdc_crtc_set_panel_info(encoder->crtc, &dvi_info);
 }
 
 static void tfp410_encoder_commit(struct drm_encoder *encoder)
@@ -276,6 +275,7 @@ static int tfp410_modeset_init(struct tilcdc_module *mod, struct drm_device *dev
        priv->encoders[priv->num_encoders++] = encoder;
        priv->connectors[priv->num_connectors++] = connector;
 
+       tilcdc_crtc_set_panel_info(priv->crtc, &dvi_info);
        return 0;
 }