[{"id":1770653,"web_url":"http://patchwork.ozlabs.org/comment/1770653/","msgid":"<CA+E=qVfsbMmWvKcThbzwrSQLihKTqzx-sb4PQSebhpaMzLnu0Q@mail.gmail.com>","list_archive_url":null,"date":"2017-09-19T04:59:50","subject":"Re: [U-Boot] [PATCH 1/5] dm: video: bridge: add operation to read\n\tEDID","submitter":{"id":6930,"url":"http://patchwork.ozlabs.org/api/people/6930/","name":"Vasily Khoruzhick","email":"anarsoul@gmail.com"},"content":"Please discard this, I forgot to include maintainers in CC. Will resend.\n\nOn Sun, Sep 17, 2017 at 8:21 PM, Vasily Khoruzhick <anarsoul@gmail.com> wrote:\n> Bridge may have ability to read EDID from panel that is connected to it,\n> so add an operation to read EDID.\n>\n> Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>\n> ---\n>  drivers/video/bridge/video-bridge-uclass.c | 10 ++++++++++\n>  include/video_bridge.h                     | 20 ++++++++++++++++++++\n>  2 files changed, 30 insertions(+)\n>\n> diff --git a/drivers/video/bridge/video-bridge-uclass.c b/drivers/video/bridge/video-bridge-uclass.c\n> index 07270bac9e..79facd02a6 100644\n> --- a/drivers/video/bridge/video-bridge-uclass.c\n> +++ b/drivers/video/bridge/video-bridge-uclass.c\n> @@ -8,6 +8,7 @@\n>  #include <common.h>\n>  #include <dm.h>\n>  #include <errno.h>\n> +#include <edid.h>\n>  #include <video_bridge.h>\n>\n>  int video_bridge_set_backlight(struct udevice *dev, int percent)\n> @@ -45,6 +46,15 @@ int video_bridge_check_attached(struct udevice *dev)\n>         return ops->check_attached(dev);\n>  }\n>\n> +int video_bridge_read_edid(struct udevice *dev, u8 *buf, int buf_size)\n> +{\n> +       struct video_bridge_ops *ops = video_bridge_get_ops(dev);\n> +\n> +       if (!ops || !ops->read_edid)\n> +               return -ENOSYS;\n> +       return ops->read_edid(dev, buf, buf_size);\n> +}\n> +\n>  static int video_bridge_pre_probe(struct udevice *dev)\n>  {\n>         struct video_bridge_priv *uc_priv = dev_get_uclass_priv(dev);\n> diff --git a/include/video_bridge.h b/include/video_bridge.h\n> index c7b8681849..0699a8dda8 100644\n> --- a/include/video_bridge.h\n> +++ b/include/video_bridge.h\n> @@ -53,6 +53,16 @@ struct video_bridge_ops {\n>          * @return 0 if OK, -ve on error\n>          */\n>         int (*set_backlight)(struct udevice *dev, int percent);\n> +\n> +       /**\n> +        * read_edid() - Read information from EDID\n> +        *\n> +        * @dev:        Device to read from\n> +        * @buf:        Buffer to read into\n> +        * @buf_size:   Buffer size\n> +        * @return number of bytes read, <=0 for error\n> +        */\n> +       int (*read_edid)(struct udevice *dev, u8 *buf, int buf_size);\n>  };\n>\n>  #define video_bridge_get_ops(dev) \\\n> @@ -89,4 +99,14 @@ int video_bridge_set_active(struct udevice *dev, bool active);\n>   */\n>  int video_bridge_check_attached(struct udevice *dev);\n>\n> +/**\n> + * video_bridge_read_edid() - Read information from EDID\n> + *\n> + * @dev:       Device to read from\n> + * @buf:       Buffer to read into\n> + * @buf_size:  Buffer size\n> + * @return number of bytes read, <=0 for error\n> + */\n> +int video_bridge_read_edid(struct udevice *dev, u8 *buf, int buf_size);\n> +\n>  #endif\n> --\n> 2.14.1\n>","headers":{"Return-Path":"<u-boot-bounces@lists.denx.de>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":["ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=lists.denx.de\n\t(client-ip=81.169.180.215; helo=lists.denx.de;\n\tenvelope-from=u-boot-bounces@lists.denx.de;\n\treceiver=<UNKNOWN>)","ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=gmail.com header.i=@gmail.com\n\theader.b=\"UMoP+57o\"; dkim-atps=neutral"],"Received":["from lists.denx.de (dione.denx.de [81.169.180.215])\n\tby ozlabs.org (Postfix) with ESMTP id 3xx9jC4KRSz9s5L\n\tfor <incoming@patchwork.ozlabs.org>;\n\tTue, 19 Sep 2017 15:02:23 +1000 (AEST)","by lists.denx.de (Postfix, from userid 105)\n\tid 5C109C21D72; Tue, 19 Sep 2017 05:02:20 +0000 (UTC)","from lists.denx.de (localhost [IPv6:::1])\n\tby lists.denx.de (Postfix) with ESMTP id ED819C21D72;\n\tTue, 19 Sep 2017 05:01:45 +0000 (UTC)","by lists.denx.de (Postfix, from userid 105)\n\tid E1DBCC21D72; Tue, 19 Sep 2017 05:01:44 +0000 (UTC)","from mail-io0-f193.google.com (mail-io0-f193.google.com\n\t[209.85.223.193])\n\tby lists.denx.de (Postfix) with ESMTPS id BC984C21D90\n\tfor <u-boot@lists.denx.de>; Tue, 19 Sep 2017 05:00:12 +0000 (UTC)","by mail-io0-f193.google.com with SMTP id 93so3453104iol.4\n\tfor <u-boot@lists.denx.de>; Mon, 18 Sep 2017 22:00:12 -0700 (PDT)","by 10.157.9.69 with HTTP; Mon, 18 Sep 2017 21:59:50 -0700 (PDT)"],"X-Spam-Checker-Version":"SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de","X-Spam-Level":"","X-Spam-Status":"No, score=0.0 required=5.0 tests=FREEMAIL_FROM,\n\tRCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,\n\tT_DKIM_INVALID autolearn=unavailable\n\tautolearn_force=no version=3.4.0","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;\n\th=mime-version:in-reply-to:references:from:date:message-id:subject:to\n\t:cc; bh=IAG/Zll4l9n+Y4OtJMIBiPO1vjuD9q3JuDDPXqPSPPc=;\n\tb=UMoP+57oufrHzOkIs94IRz3mItIus6DkcKEi4VFMkAJ/Lgx3K4y+KC4XwX1/WBIROz\n\tBYg9ckkWrwkBVJXfwIXFpt56vbBCLrnIYl+qx81kVxKXw35e7HFUAbBMQHrS21P0xWP9\n\tkLteoLNuOcLQeNAA1xklFiJlsvWN1iK67eRWHW50EGRCAzq+XaKAX4sFudEn1tI9yAaZ\n\tlH7nCNlfygqcuqPGzVLooU+a/VOXeU6L2BDwOon6nMuMjdn6rHewSmgHpY/35Rx8JS+W\n\tvxy0B2apM3GmY/G0eePB9+34j5d56/bGFPm3jOibIQmnRKS0q5J1mB77XNza4J+srpZf\n\t39Fg==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:mime-version:in-reply-to:references:from:date\n\t:message-id:subject:to:cc;\n\tbh=IAG/Zll4l9n+Y4OtJMIBiPO1vjuD9q3JuDDPXqPSPPc=;\n\tb=QNGFL1W5iAy1y8ta0h3v2JLgEOqKYV2W6udp8coXzFlll0WFtxQWuSQ3vLUqPbN4pW\n\tFiBAuX2oBaxLkXnmjlz7r7Qtb1OLdyCeodXB2uBuJh05dsSUgmu+GuydbgmAanF3tWyr\n\t2JDY6BgVkG+KXybTCerPZCQKxfCbxakWRlAsj4Jy0MJ0J2a1/Ki8Cl4twGEWTLlefLvq\n\teQmr2nj30ivybyKQ89dPty9oSoiyjjHW4XOuKgJuS7hroK1g3uNODPJi34WfCAvhleNX\n\t3U9n/AD7TfANIu1nmojNFB/smF44n+RaFWIwxB9rpo82lBVSixrYjSYBx30CFFVnTy3G\n\tR5rg==","X-Gm-Message-State":"AHPjjUjgjoSS216KOuZMxGFF4QSLrOXa2kfIfraOdoZZg62sXVgpCLKV\n\txcdTScGEdUxLtfzBBP1EYuYM1/TaczXWONKPOlpmLg==","X-Google-Smtp-Source":"AOwi7QAtxBfWMhGlQl7X1WGa/tYrz31+V1ckSibchG9W5nUcMJLXnWr24EVGErITKPHN1SVb+gB2gkZFT9oDeIzxJ5g=","X-Received":"by 10.202.84.11 with SMTP id i11mr170332oib.152.1505797210925;\n\tMon, 18 Sep 2017 22:00:10 -0700 (PDT)","MIME-Version":"1.0","In-Reply-To":"<20170918032145.25349-1-anarsoul@gmail.com>","References":"<20170918032145.25349-1-anarsoul@gmail.com>","From":"Vasily Khoruzhick <anarsoul@gmail.com>","Date":"Mon, 18 Sep 2017 21:59:50 -0700","Message-ID":"<CA+E=qVfsbMmWvKcThbzwrSQLihKTqzx-sb4PQSebhpaMzLnu0Q@mail.gmail.com>","To":"u-boot@lists.denx.de, jernej.skrabec@siol.net, icenowy@aosc.io","Subject":"Re: [U-Boot] [PATCH 1/5] dm: video: bridge: add operation to read\n\tEDID","X-BeenThere":"u-boot@lists.denx.de","X-Mailman-Version":"2.1.18","Precedence":"list","List-Id":"U-Boot discussion <u-boot.lists.denx.de>","List-Unsubscribe":"<https://lists.denx.de/options/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>","List-Archive":"<http://lists.denx.de/pipermail/u-boot/>","List-Post":"<mailto:u-boot@lists.denx.de>","List-Help":"<mailto:u-boot-request@lists.denx.de?subject=help>","List-Subscribe":"<https://lists.denx.de/listinfo/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=subscribe>","Content-Type":"text/plain; charset=\"utf-8\"","Content-Transfer-Encoding":"base64","Errors-To":"u-boot-bounces@lists.denx.de","Sender":"\"U-Boot\" <u-boot-bounces@lists.denx.de>"}}]