lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAOw6vb+a2SAq+=xfL9RZyA6R7zn-HYFQbDnDaK28TD8yrh+wLg@mail.gmail.com>
Date:   Fri, 18 Jan 2019 12:58:10 -0500
From:   Sean Paul <seanpaul@...omium.org>
To:     "Hsin-Yi, Wang" <hsinyi@...omium.org>
Cc:     Linux ARM Kernel <linux-arm-kernel@...ts.infradead.org>,
        Thierry Reding <thierry.reding@...il.com>,
        David Airlie <airlied@...ux.ie>,
        Daniel Vetter <daniel@...ll.ch>,
        dri-devel <dri-devel@...ts.freedesktop.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH resend] drm/panel: panel-innolux: set display off in innolux_panel_unprepare

On Wed, Jan 9, 2019 at 1:59 AM Hsin-Yi, Wang <hsinyi@...omium.org> wrote:
>
> Move mipi_dsi_dcs_set_display_off() from innolux_panel_disable()
> to innolux_panel_unprepare(), so they are consistent with
> innolux_panel_enable() and innolux_panel_prepare().
>
> This also fixes some mode check and irq timeout issue in MTK dsi code.
>
> Since some dsi code (e.g. mtk_dsi) have following call trace:
> 1. drm_panel_disable(), which calls innolux_panel_disable()
> 2. switch to cmd mode
> 3. drm_panel_unprepare(), which calls innolux_panel_unprepare()
>
> However, mtk_dsi needs to be in cmd mode to be able to send commands
> (e.g. mipi_dsi_dcs_set_display_off() and mipi_dsi_dcs_enter_sleep_mode()),
> so we need these functions to be called after the switch to cmd mode happens,
> i.e. in innolux_panel_unprepare.
>
>
> Signed-off-by: Hsin-Yi, Wang <hsinyi@...omium.org>

Reviewed-by: Sean Paul <seanpaul@...omium.org>

> ---
> Resend for review.
> ---
>  drivers/gpu/drm/panel/panel-innolux-p079zca.c | 11 +++++------
>  1 file changed, 5 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/gpu/drm/panel/panel-innolux-p079zca.c b/drivers/gpu/drm/panel/panel-innolux-p079zca.c
> index ca4ae45dd307..8e5724b63f1f 100644
> --- a/drivers/gpu/drm/panel/panel-innolux-p079zca.c
> +++ b/drivers/gpu/drm/panel/panel-innolux-p079zca.c
> @@ -70,18 +70,12 @@ static inline struct innolux_panel *to_innolux_panel(struct drm_panel *panel)
>  static int innolux_panel_disable(struct drm_panel *panel)
>  {
>         struct innolux_panel *innolux = to_innolux_panel(panel);
> -       int err;
>
>         if (!innolux->enabled)
>                 return 0;
>
>         backlight_disable(innolux->backlight);
>
> -       err = mipi_dsi_dcs_set_display_off(innolux->link);
> -       if (err < 0)
> -               DRM_DEV_ERROR(panel->dev, "failed to set display off: %d\n",
> -                             err);
> -
>         innolux->enabled = false;
>
>         return 0;
> @@ -95,6 +89,11 @@ static int innolux_panel_unprepare(struct drm_panel *panel)
>         if (!innolux->prepared)
>                 return 0;
>
> +       err = mipi_dsi_dcs_set_display_off(innolux->link);
> +       if (err < 0)
> +               DRM_DEV_ERROR(panel->dev, "failed to set display off: %d\n",
> +                             err);
> +
>         err = mipi_dsi_dcs_enter_sleep_mode(innolux->link);
>         if (err < 0) {
>                 DRM_DEV_ERROR(panel->dev, "failed to enter sleep mode: %d\n",
> --
> 2.18.1
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ