|
@@ -491,7 +491,8 @@ static void sun4i_tcon0_mode_set_rgb(struct sun4i_tcon *tcon,
|
|
sun4i_tcon0_mode_set_common(tcon, mode);
|
|
sun4i_tcon0_mode_set_common(tcon, mode);
|
|
|
|
|
|
/* Set dithering if needed */
|
|
/* Set dithering if needed */
|
|
- sun4i_tcon0_mode_set_dithering(tcon, tcon->panel->connector);
|
|
|
|
|
|
+ if (tcon->panel)
|
|
|
|
+ sun4i_tcon0_mode_set_dithering(tcon, tcon->panel->connector);
|
|
|
|
|
|
/* Adjust clock delay */
|
|
/* Adjust clock delay */
|
|
clk_delay = sun4i_tcon_get_clk_delay(mode, 0);
|
|
clk_delay = sun4i_tcon_get_clk_delay(mode, 0);
|
|
@@ -555,7 +556,7 @@ static void sun4i_tcon0_mode_set_rgb(struct sun4i_tcon *tcon,
|
|
* Following code is a way to avoid quirks all around TCON
|
|
* Following code is a way to avoid quirks all around TCON
|
|
* and DOTCLOCK drivers.
|
|
* and DOTCLOCK drivers.
|
|
*/
|
|
*/
|
|
- if (!IS_ERR(tcon->panel)) {
|
|
|
|
|
|
+ if (tcon->panel) {
|
|
struct drm_panel *panel = tcon->panel;
|
|
struct drm_panel *panel = tcon->panel;
|
|
struct drm_connector *connector = panel->connector;
|
|
struct drm_connector *connector = panel->connector;
|
|
struct drm_display_info display_info = connector->display_info;
|
|
struct drm_display_info display_info = connector->display_info;
|