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: <CABkfQAHcphPs=stWuT8XAFfbZnhx8sp9E_8i0nTgcMxoJp7agQ@mail.gmail.com>
Date:   Thu, 22 Sep 2022 20:24:36 +0200
From:   Adrien Grassein <adrien.grassein@...il.com>
To:     Philippe Schenker <dev@...henker.ch>
Cc:     dri-devel <dri-devel@...ts.freedesktop.org>,
        Jernej Skrabec <jernej.skrabec@...il.com>,
        Jonas Karlman <jonas@...boo.se>,
        Robert Foss <robert.foss@...aro.org>,
        linux-kernel <linux-kernel@...r.kernel.org>,
        Daniel Vetter <daniel@...ll.ch>,
        Neil Armstrong <neil.armstrong@...aro.org>,
        Laurent Pinchart <Laurent.pinchart@...asonboard.com>,
        Andrzej Hajda <andrzej.hajda@...el.com>,
        David Airlie <airlied@...ux.ie>,
        Philippe Schenker <philippe.schenker@...adex.com>
Subject: Re: [PATCH 1/4] drm/bridge: lt8912b: add vsync hsync

Le jeu. 22 sept. 2022 à 14:43, Philippe Schenker <dev@...henker.ch> a écrit :
>
> From: Philippe Schenker <philippe.schenker@...adex.com>
>
> Currently the bridge driver does not take care whether or not the display
> needs positive/negative vertical/horizontal syncs. Pass these two flags
> to the bridge from the EDID that was read out from the display.
>
> Fixes: 30e2ae943c26 ("drm/bridge: Introduce LT8912B DSI to HDMI bridge")
> Signed-off-by: Philippe Schenker <philippe.schenker@...adex.com>
Acked-by: Adrien Grassein <adrien.grassein@...il.com>
>
> ---
>
>  drivers/gpu/drm/bridge/lontium-lt8912b.c | 9 ++++++++-
>  1 file changed, 8 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/bridge/lontium-lt8912b.c b/drivers/gpu/drm/bridge/lontium-lt8912b.c
> index 28bad30dc4e5..0fd3472e767c 100644
> --- a/drivers/gpu/drm/bridge/lontium-lt8912b.c
> +++ b/drivers/gpu/drm/bridge/lontium-lt8912b.c
> @@ -268,7 +268,7 @@ static int lt8912_video_setup(struct lt8912 *lt)
>         u32 hactive, h_total, hpw, hfp, hbp;
>         u32 vactive, v_total, vpw, vfp, vbp;
>         u8 settle = 0x08;
> -       int ret;
> +       int ret, hsync_activehigh, vsync_activehigh;
>
>         if (!lt)
>                 return -EINVAL;
> @@ -278,12 +278,14 @@ static int lt8912_video_setup(struct lt8912 *lt)
>         hpw = lt->mode.hsync_len;
>         hbp = lt->mode.hback_porch;
>         h_total = hactive + hfp + hpw + hbp;
> +       hsync_activehigh = lt->mode.flags & DISPLAY_FLAGS_HSYNC_HIGH;
>
>         vactive = lt->mode.vactive;
>         vfp = lt->mode.vfront_porch;
>         vpw = lt->mode.vsync_len;
>         vbp = lt->mode.vback_porch;
>         v_total = vactive + vfp + vpw + vbp;
> +       vsync_activehigh = lt->mode.flags & DISPLAY_FLAGS_VSYNC_HIGH;
>
>         if (vactive <= 600)
>                 settle = 0x04;
> @@ -317,6 +319,11 @@ static int lt8912_video_setup(struct lt8912 *lt)
>         ret |= regmap_write(lt->regmap[I2C_CEC_DSI], 0x3e, hfp & 0xff);
>         ret |= regmap_write(lt->regmap[I2C_CEC_DSI], 0x3f, hfp >> 8);
>
> +       ret |= regmap_update_bits(lt->regmap[I2C_MAIN], 0xab, BIT(0),
> +                                 vsync_activehigh ? BIT(0) : 0);
> +       ret |= regmap_update_bits(lt->regmap[I2C_MAIN], 0xab, BIT(1),
> +                                 hsync_activehigh ? BIT(1) : 0);
> +
>         return ret;
>  }
>
> --
> 2.37.3
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ