dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
From: Daniel Dadap <ddadap@nvidia.com>
To: Anisse Astier <anisse@astier.eu>,
	Ville Syrj?l? <ville.syrjala@linux.intel.com>
Cc: Jani Nikula <jani.nikula@intel.com>,
	Hans de Goede <hdegoede@redhat.com>,
	intel-gfx@lists.freedesktop.org,
	Uma Shankar <uma.shankar@intel.com>,
	dri-devel@lists.freedesktop.org
Subject: Re: [PATCH v2 1/2] drm/i915/opregion: add support for mailbox #5 EDID
Date: Wed, 7 Jul 2021 14:57:47 -0500	[thread overview]
Message-ID: <43427294-b19b-f32e-3b75-479eac6628ca@nvidia.com> (raw)
In-Reply-To: <YLa22EBqxE2sBdpp@bilrost>

On 6/1/21 5:43 PM, Anisse Astier wrote:
>
> Le Tue, Jun 01, 2021 at 06:50:24PM +0300, Ville Syrj?l? a ?crit :
>> On Mon, May 31, 2021 at 10:46:41PM +0200, Anisse Astier wrote:
>>> The ACPI OpRegion Mailbox #5 ASLE extension may contain an EDID to be
>>> used for the embedded display. Add support for using it via by adding
>>> the EDID to the list of available modes on the connector, and use it for
>>> eDP when available.
>>>
>>> If a panel's EDID is broken, there may be an override EDID set in the
>>> ACPI OpRegion mailbox #5. Use it if available.
>> Looks like Windows uses the ACPI _DDC method instead. We should probably
>> do the same, just in case some crazy machine stores the EDID somewhere
>> else.
> Thanks, I wouldn't have thought of this. It seems Daniel Dadap did a
> patch series to do just that, in a generic way:
> https://lore.kernel.org/amd-gfx/20200727205357.27839-1-ddadap@nvidia.com/
>
> I've tried patch 1 & 2, and after a fix[1] was able to call the _DDC method
> on most devices, but without any EDID being returned.
>
> I looked at the disassembled ACPI tables[2], and could not find any
> device with the _DDC method. Are you sure it's the only method the
> Windows driver uses to get the EDID ?


_DDC only works on devices that actually implement it, and the vast 
majority of devices don't, because the display just provides an EDID 
normally. AIUI, usually a device will implement _DDC either because an 
embedded panel has no ROM of its own to deliver an EDID, or to allow the 
EDID to be read by either GPU on a system with a muxed display, 
regardless of which GPU happens to have the DDC lines (in TMDS) or DP 
AUX routed to it at the moment. (To my knowledge, nobody actually muxes 
DP AUX independently from the main link, but there were some older 
pre-DP designs where DDC could be muxed independently.)

I'm not sure whether the comment about Windows using _DDC was meant for 
this device in particular, or just more generally, since DDC is part of 
the ACPI spec and some Windows GPU drivers *do* use it, where available. 
If it was meant for a particular device, then it's possible that the 
ACPI tables advertise different methods depending on e.g. _OSI. If you 
haven't already tried doing so, it might be worth overriding _OSI to 
spoof Windows, to see if _DDC gets advertised.

I'm not sure how you were able to call _DDC without an EDID being 
returned as described above, if there was no _DDC method in the ACPI 
tables; I would expect that attempting to call _DDC would fail to locate 
a suitable method and do_acpi_ddc would return NULL.


> Regards,
>
> Anisse
>
> [1] _DOD ids should only use 16 lower bits, see table here:
> https://uefi.org/specs/ACPI/6.4/Apx_B_Video_Extensions/display-specific-methods.html#dod-enumerate-all-devices-attached-to-the-display-adapter


Thanks; I don't see a version of your modified patch here, was the fix 
just to mask the _DOD IDs against 0xffff?


> [2] acpidump: https://gitlab.freedesktop.org/drm/intel/-/issues/3454#note_913970
>

  reply	other threads:[~2021-07-08  7:08 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-31 20:46 [PATCH v2 0/2] GPD Win Max display fixes Anisse Astier
2021-05-31 20:46 ` [PATCH v2 1/2] drm/i915/opregion: add support for mailbox #5 EDID Anisse Astier
2021-06-01 15:50   ` Ville Syrjälä
2021-06-01 22:43     ` Anisse Astier
2021-07-07 19:57       ` Daniel Dadap [this message]
2021-07-07 21:30         ` Anisse Astier
2021-05-31 20:46 ` [PATCH v2 2/2] drm: Add orientation quirk for GPD Win Max Anisse Astier

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=43427294-b19b-f32e-3b75-479eac6628ca@nvidia.com \
    --to=ddadap@nvidia.com \
    --cc=anisse@astier.eu \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=hdegoede@redhat.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jani.nikula@intel.com \
    --cc=uma.shankar@intel.com \
    --cc=ville.syrjala@linux.intel.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).