They're not necessary for atomic drivers, and drm_panel will WARN if the calls are unbalanced Signed-off-by: Sean Paul <seanpaul@xxxxxxxxxxxx> --- drivers/gpu/drm/panel/panel-innolux-p079zca.c | 23 ----------------------- 1 file changed, 23 deletions(-) diff --git a/drivers/gpu/drm/panel/panel-innolux-p079zca.c b/drivers/gpu/drm/panel/panel-innolux-p079zca.c index 6ba93449fcfb..38b19c8de9e1 100644 --- a/drivers/gpu/drm/panel/panel-innolux-p079zca.c +++ b/drivers/gpu/drm/panel/panel-innolux-p079zca.c @@ -27,9 +27,6 @@ struct innolux_panel { struct backlight_device *backlight; struct regulator *supply; struct gpio_desc *enable_gpio; - - bool prepared; - bool enabled; }; static inline struct innolux_panel *to_innolux_panel(struct drm_panel *panel) @@ -42,9 +39,6 @@ static int innolux_panel_disable(struct drm_panel *panel) struct innolux_panel *innolux = to_innolux_panel(panel); int err; - if (!innolux->enabled) - return 0; - innolux->backlight->props.power = FB_BLANK_POWERDOWN; backlight_update_status(innolux->backlight); @@ -53,8 +47,6 @@ static int innolux_panel_disable(struct drm_panel *panel) DRM_DEV_ERROR(panel->dev, "failed to set display off: %d\n", err); - innolux->enabled = false; - return 0; } @@ -63,9 +55,6 @@ static int innolux_panel_unprepare(struct drm_panel *panel) struct innolux_panel *innolux = to_innolux_panel(panel); int err; - if (!innolux->prepared) - return 0; - err = mipi_dsi_dcs_enter_sleep_mode(innolux->link); if (err < 0) { DRM_DEV_ERROR(panel->dev, "failed to enter sleep mode: %d\n", @@ -82,8 +71,6 @@ static int innolux_panel_unprepare(struct drm_panel *panel) if (err < 0) return err; - innolux->prepared = false; - return 0; } @@ -92,9 +79,6 @@ static int innolux_panel_prepare(struct drm_panel *panel) struct innolux_panel *innolux = to_innolux_panel(panel); int err, regulator_err; - if (innolux->prepared) - return 0; - gpiod_set_value_cansleep(innolux->enable_gpio, 0); err = regulator_enable(innolux->supply); @@ -129,8 +113,6 @@ static int innolux_panel_prepare(struct drm_panel *panel) /* T7: 5ms */ usleep_range(5000, 6000); - innolux->prepared = true; - return 0; poweroff: @@ -148,9 +130,6 @@ static int innolux_panel_enable(struct drm_panel *panel) struct innolux_panel *innolux = to_innolux_panel(panel); int ret; - if (innolux->enabled) - return 0; - innolux->backlight->props.power = FB_BLANK_UNBLANK; ret = backlight_update_status(innolux->backlight); if (ret) { @@ -159,8 +138,6 @@ static int innolux_panel_enable(struct drm_panel *panel) return ret; } - innolux->enabled = true; - return 0; } -- 2.15.0.rc0.271.g36b669edcc-goog _______________________________________________ dri-devel mailing list dri-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/dri-devel