All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Marc-André Lureau" <marcandre.lureau@gmail.com>
To: Gerd Hoffmann <kraxel@redhat.com>
Cc: QEMU <qemu-devel@nongnu.org>
Subject: Re: [PATCH v2 4/8] edid: use dta extension block descriptors
Date: Tue, 27 Apr 2021 19:59:08 +0400	[thread overview]
Message-ID: <CAJ+F1CKCw+0n8ZoTLekryZGNP8HRHSrJDO1J2F=zaGqdMQkBXQ@mail.gmail.com> (raw)
In-Reply-To: <20210427150824.638359-5-kraxel@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 1196 bytes --]

On Tue, Apr 27, 2021 at 7:23 PM Gerd Hoffmann <kraxel@redhat.com> wrote:

> When the 4 descriptors in the base edid block are filled, jump to the
> dta extension block.  This allows for more than four descriptors.
> Happens for example when generating an edid blob with a serial number
> (qemu-edid -s $serial).
>
> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
>

Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>

---
>  hw/display/edid-generate.c | 8 ++++++++
>  1 file changed, 8 insertions(+)
>
> diff --git a/hw/display/edid-generate.c b/hw/display/edid-generate.c
> index 25f790c7bd85..42a130f0ff5c 100644
> --- a/hw/display/edid-generate.c
> +++ b/hw/display/edid-generate.c
> @@ -152,6 +152,14 @@ static uint8_t *edid_desc_next(uint8_t *edid, uint8_t
> *dta, uint8_t *desc)
>      if (desc + 18 + 18 < edid + 127) {
>          return desc + 18;
>      }
> +    if (dta) {
> +        if (desc < edid + 127) {
> +            return dta + dta[2];
> +        }
> +        if (desc + 18 + 18 < dta + 127) {
> +            return desc + 18;
> +        }
> +    }
>      return NULL;
>  }
>
> --
> 2.30.2
>
>
>

-- 
Marc-André Lureau

[-- Attachment #2: Type: text/html, Size: 1981 bytes --]

  reply	other threads:[~2021-04-27 16:01 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-27 15:08 [PATCH v2 0/8] edid: windows fixes Gerd Hoffmann
2021-04-27 15:08 ` [PATCH v2 1/8] qemu-edid: use qemu_edid_size() Gerd Hoffmann
2021-04-27 15:53   ` Marc-André Lureau
2021-04-27 15:08 ` [PATCH v2 2/8] edid: edid_desc_next Gerd Hoffmann
2021-04-27 15:53   ` Marc-André Lureau
2021-04-27 15:08 ` [PATCH v2 3/8] edid: move xtra3 descriptor Gerd Hoffmann
2021-04-27 15:54   ` Marc-André Lureau
2021-04-27 15:08 ` [PATCH v2 4/8] edid: use dta extension block descriptors Gerd Hoffmann
2021-04-27 15:59   ` Marc-André Lureau [this message]
2021-04-27 15:08 ` [PATCH v2 5/8] edid: Make refresh rate configurable Gerd Hoffmann
2021-04-27 15:08 ` [PATCH v2 6/8] edid: move timing generation into a separate function Gerd Hoffmann
2021-04-27 15:08 ` [PATCH v2 7/8] edid: allow arbitrary-length checksums Gerd Hoffmann
2021-04-27 15:08 ` [PATCH v2 8/8] edid: add support for DisplayID extension (5k resolution) Gerd Hoffmann
2021-04-27 15:27 ` [PATCH v2 0/8] edid: windows fixes no-reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAJ+F1CKCw+0n8ZoTLekryZGNP8HRHSrJDO1J2F=zaGqdMQkBXQ@mail.gmail.com' \
    --to=marcandre.lureau@gmail.com \
    --cc=kraxel@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.