Skip to content

DRM/KMS/EDID: Various EDID handling related fixes.

Egbert Eich dri-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v2 Latest18 patches 6 repliesIn review

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/18DRM/KMS/EDID: Mask out Segment Bits when calculating Offset.drivers/gpu/drm/drm_edid.c+1 -10 replies
2/18DRM/KMS/EDID: 0x7e -> EDID_EXTENSION_FLAG_OFFSET (v2)drivers/gpu/drm/drm_edid.c+9 -70 replies
3/18DRM/KMS/EDID: Return Base EDID block if reading EEDID Blocks fails (v2)drivers/gpu/drm/drm_edid.c+5 -20 replies
4/18DRM/KMS/EDID: Don't fail when failing to allocate memory for EDID extensions.drivers/gpu/drm/drm_edid.c+5 -20 replies
5/18DRM/KMS/EDID: Test EDDC if EDID announces more than one Extension Block (v2)drivers/gpu/drm/drm_edid.c+13 -05 replies
6/18DRM/KMS/EDID: Don't expect extension blocks for EDID Versions < 1.3.drivers/gpu/drm/drm_edid.c+6 -00 replies
7/18DRM/KMS/EDID: Don't reallocate EDID blob when size has shrunk.drivers/gpu/drm/drm_edid.c+0 -40 replies
8/18DRM/KMS/EDID: Fix up EEDID Map Blogs if Extension Block Count has changed (v2)drivers/gpu/drm/drm_edid.c+89 -00 replies
9/18DRM/KMS/EDID: Move drm_edid_load.o to drm.ko (v2)drivers/gpu/drm/Kconfig drivers/gpu/drm/Makefile+3 -20 replies
10/18DRM/KMS/EDID: Feed 'firmware' supplied EDID blocks whenever the EDID is read (v2)drivers/gpu/drm/drm_crtc_helper.c drivers/gpu/drm/drm_edid.c drivers/gpu/drm/drm_edid_load.c +1 more+20 -190 replies
11/18DRM/KMS/EDID: Allow for multiple Connectors when specifying 'firmware'-EDID Files (v2)drivers/gpu/drm/drm_edid_load.c+31 -140 replies
12/18DRM/KMS/EDID: Use Extension Block Fixup Code also for 'firmware' EDID (v2)drivers/gpu/drm/drm_edid.c drivers/gpu/drm/drm_edid_load.c include/drm/drm_edid.h+71 -480 replies
13/18DRM/KMS/EDID: Cache EDID blobs with extensions (v2)drivers/gpu/drm/drm_crtc.c drivers/gpu/drm/drm_edid.c include/drm/drm_crtc.h +1 more+52 -83 replies
14/18DRM/KMS/EDID: Consolidate EDID Error Handling (v2)drivers/gpu/drm/drm_edid.c drivers/gpu/drm/radeon/radeon_connectors.c include/drm/drm_crtc.h +1 more+81 -507 replies
15/18DRM/KMS/ast: Include drm_edid.h in file using drm_get_edid().drivers/gpu/drm/ast/ast_mode.c+1 -00 replies
16/18DRM/KMS/gma500: Include drm_edid.h in file using drm_get_edid().drivers/gpu/drm/gma500/cdv_intel_dp.c drivers/gpu/drm/gma500/oaktrail_lvds.c drivers/gpu/drm/gma500/psb_intel_modes.c+3 -00 replies
17/18DRM/KMS/mgag200: Include drm_edid.h in file using drm_get_edid().drivers/gpu/drm/mgag200/mgag200_mode.c+1 -00 replies
18/18DRM/KMS/EDID: Move EDID related Functions to drm_edid.h.include/drm/drm_crtc.h include/drm/drm_edid.h+9 -80 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH v2 00/18] DRM/KMS/EDID: Various EDID handling related fixes.

The patches have been reordered and the changes suggested by Takashi Iwai have been worked in.

Egbert Eich (18):

1. Make error handling of EDID extension blocks a bit more fault tolorant:
* Don't fail when EDID extension blocks cannot be read or memory cannot be allocated.
* Don't read EDID extension blocks there are no blocks to expect, either for EDID versions < 1.3
or when block 3 is equal to the base block (in which case the monitor is not EDDC capable and doesn't accept the segment address.

DRM/KMS/EDID: Mask out Segment Bits when calculating Offset. DRM/KMS/EDID: 0x7e -> EDID_EXTENSION_FLAG_OFFSET (v2) DRM/KMS/EDID: Return Base EDID block if reading EEDID Blocks fails (v2) DRM/KMS/EDID: Don't fail when failing to allocate memory for EDID extensions. DRM/KMS/EDID: Test EDDC if EDID announces more than one Extension Block (v2) DRM/KMS/EDID: Don't expect extension blocks for EDID Versions < 1.3. DRM/KMS/EDID: Don't reallocate EDID blob when size has shrunk.

2. Fix EDID block maps:
We skip invalid EEDID blocks, if we do so however we should fix the block maps to keep the EDID consistent.

DRM/KMS/EDID: Fix up EEDID Map Blogs if Extension Block Count has changed (v2)

3. Improve handling of 'firmware'-supplied EDIDs:
* Move EDID loading from a helper level to DRM core.
* If there is a 'firmware'-supplied EDID matching the connector supply it whenever drm_get_edid() is called.
* Allow to specify firmware for multiple connectors.
* Use the same EDID fault handling as for DDC read EDIDs.

DRM/KMS/EDID: Move drm_edid_load.o to drm.ko (v2)
DRM/KMS/EDID: Feed 'firmware' supplied EDID blocks whenever the EDID is read (v2) DRM/KMS/EDID: Allow for multiple Connectors when specifying
'firmware'-EDID Files (v2)
DRM/KMS/EDID: Use Extension Block Fixup Code also for 'firmware' EDID (v2)

4. Cache EDIDs with extension blocks.
I2C transfer of EDIDs with several extension blocks can be quite time consuming. In many cases the EDID has not changed for a given connector since the last read. We detect this by comparing data from the base block. If a match is found we copy the EDID data from cache. This way only the base block needs to be transferred.

DRM/KMS/EDID: Cache EDID blobs with extensions (v2)

5. Consolidate EDID fatal error handling:
Store information about the error status of the last DDC read in the drm_connector structure.
It combines the handling of all zero EDIDs (needed by the radeon driver) and the suppression of consecutive logging of the same EDID error. It will log again when the error pattern has changed (for inststance if the monitor has been exchanged).

DRM/KMS/EDID: Consolidate EDID Error Handling (v2)

6. Move EDID-related functions to drm_edid.h
The handling of EDID related DRM functions seemed to be a bit arbitrary:
although drm_edid.h had been created, new functions were often added to drm_crtc.h

DRM/KMS/ast: Include drm_edid.h in file using drm_get_edid(). DRM/KMS/gma500: Include drm_edid.h in file using drm_get_edid(). DRM/KMS/mgag200: Include drm_edid.h in file using drm_get_edid(). DRM/KMS/EDID: Move EDID related Functions to drm_edid.h.

 drivers/gpu/drm/Kconfig                    |    3 +-
 drivers/gpu/drm/Makefile                   |    2 +-
 drivers/gpu/drm/ast/ast_mode.c             |    1 +
 drivers/gpu/drm/drm_crtc.c                 |    1 +
 drivers/gpu/drm/drm_crtc_helper.c          |    6 +-
 drivers/gpu/drm/drm_edid.c                 |  333 ++++++++++++++++++++++++----
 drivers/gpu/drm/drm_edid_load.c            |  115 ++++------
 drivers/gpu/drm/gma500/cdv_intel_dp.c      |    1 +
 drivers/gpu/drm/gma500/oaktrail_lvds.c     |    1 +
 drivers/gpu/drm/gma500/psb_intel_modes.c   |    1 +
 drivers/gpu/drm/mgag200/mgag200_mode.c     |    1 +
 drivers/gpu/drm/radeon/radeon_connectors.c |    2 +-
 include/drm/drm_crtc.h                     |   13 +-
 include/drm/drm_edid.h                     |   25 ++-
 14 files changed, 370 insertions(+), 135 deletions(-)
Signature · 1 line
1.7.7