• Home
  • Raw
  • Download

Lines Matching full:edid

47 #define version_greater(edid, maj, min) \  argument
48 (((edid)->version > (maj)) || \
49 ((edid)->version == (maj) && (edid)->revision > (min)))
56 * EDID blocks out in the wild have a variety of bugs, try to collect
91 struct edid *edid; member
168 /* Rotel RSX-1058 forwards sink's EDID but only does HDMI 1.1*/
583 * modes are old-school Mac modes. The EDID spec says the 1152x864@75 mode
1563 * drm_edid_header_is_valid - sanity check the header of the base EDID block
1564 * @raw_edid: pointer to raw base EDID block
1566 * Sanity check the header of the base EDID block.
1585 "Minimum number of valid EDID header bytes (0-8, default 6)");
1619 * drm_edid_are_equal - compare two edid blobs.
1623 * edid had changed.
1625 bool drm_edid_are_equal(const struct edid *edid1, const struct edid *edid2) in drm_edid_are_equal()
1650 * drm_edid_block_valid - Sanity check the EDID block (base or extension)
1651 * @raw_edid: pointer to raw EDID block
1653 * @print_bad_edid: if true, dump bad EDID blocks to the console
1656 * Validate a base or extension EDID block and optionally dump bad blocks to
1665 struct edid *edid = (struct edid *)raw_edid; in drm_edid_block_valid() local
1687 DRM_DEBUG("Fixing EDID header, your hardware may be failing\n"); in drm_edid_block_valid()
1703 DRM_DEBUG("EDID checksum is invalid, remainder is %d\n", csum); in drm_edid_block_valid()
1707 DRM_NOTE("EDID checksum is invalid, remainder is %d\n", csum); in drm_edid_block_valid()
1716 if (edid->version != 1) { in drm_edid_block_valid()
1717 DRM_NOTE("EDID has major version %d, instead of 1\n", edid->version); in drm_edid_block_valid()
1721 if (edid->revision > 4) in drm_edid_block_valid()
1722 DRM_DEBUG("EDID minor > 4, assuming backward compatibility\n"); in drm_edid_block_valid()
1734 pr_notice("EDID block is all zeroes\n"); in drm_edid_block_valid()
1736 pr_notice("Raw EDID:\n"); in drm_edid_block_valid()
1747 * drm_edid_is_valid - sanity check EDID data
1748 * @edid: EDID data
1750 * Sanity-check an entire EDID record (including extensions)
1752 * Return: True if the EDID data is valid, false otherwise.
1754 bool drm_edid_is_valid(struct edid *edid) in drm_edid_is_valid() argument
1757 u8 *raw = (u8 *)edid; in drm_edid_is_valid()
1759 if (!edid) in drm_edid_is_valid()
1762 for (i = 0; i <= edid->extensions; i++) in drm_edid_is_valid()
1772 * drm_do_probe_ddc_edid() - get EDID information via I2C
1774 * @buf: EDID data buffer to be filled
1775 * @block: 128 byte EDID block to start fetching from
1776 * @len: EDID data buffer length to fetch
1778 * Try to fetch EDID information by calling I2C driver functions.
1835 u8 *edid, int num_blocks) in connector_bad_edid() argument
1841 * 0x7e in the EDID is the number of extension blocks. The EDID in connector_bad_edid()
1843 * of 0x7e in the EDID of the _index_ of the last block in the in connector_bad_edid()
1846 last_block = edid[0x7e]; in connector_bad_edid()
1848 /* Calculate real checksum for the last edid extension block data */ in connector_bad_edid()
1851 drm_edid_block_checksum(edid + last_block * EDID_LENGTH); in connector_bad_edid()
1856 drm_warn(connector->dev, "%s: EDID is invalid:\n", connector->name); in connector_bad_edid()
1858 u8 *block = edid + i * EDID_LENGTH; in connector_bad_edid()
1874 /* Get override or firmware EDID */
1875 static struct edid *drm_get_override_edid(struct drm_connector *connector) in drm_get_override_edid()
1877 struct edid *override = NULL; in drm_get_override_edid()
1889 * drm_add_override_edid_modes - add modes from override/firmware EDID
1892 * Add modes from the override/firmware EDID, if available. Only to be used from
1894 * failed during drm_get_edid() and caused the override/firmware EDID to be
1901 struct edid *override; in drm_add_override_edid_modes()
1910 DRM_DEBUG_KMS("[CONNECTOR:%d:%s] adding %d modes via fallback override/firmware EDID\n", in drm_add_override_edid_modes()
1919 * drm_do_get_edid - get EDID data using a custom EDID block read function
1921 * @get_edid_block: EDID block read function
1925 * exposes a different interface to read EDID blocks this function can be used
1926 * to get EDID data using a custom block read function.
1932 * The EDID may be overridden using debugfs override_edid or firmare EDID
1934 * order. Having either of them bypasses actual EDID reads.
1936 * Return: Pointer to valid EDID or NULL if we couldn't find any.
1938 struct edid *drm_do_get_edid(struct drm_connector *connector, in drm_do_get_edid()
1944 u8 *edid, *new; in drm_do_get_edid() local
1945 struct edid *override; in drm_do_get_edid()
1951 if ((edid = kmalloc(EDID_LENGTH, GFP_KERNEL)) == NULL) in drm_do_get_edid()
1956 if (get_edid_block(data, edid, 0, EDID_LENGTH)) in drm_do_get_edid()
1958 if (drm_edid_block_valid(edid, 0, false, in drm_do_get_edid()
1961 if (i == 0 && drm_edid_is_zero(edid, EDID_LENGTH)) { in drm_do_get_edid()
1970 valid_extensions = edid[0x7e]; in drm_do_get_edid()
1972 return (struct edid *)edid; in drm_do_get_edid()
1974 new = krealloc(edid, (valid_extensions + 1) * EDID_LENGTH, GFP_KERNEL); in drm_do_get_edid()
1977 edid = new; in drm_do_get_edid()
1979 for (j = 1; j <= edid[0x7e]; j++) { in drm_do_get_edid()
1980 u8 *block = edid + j * EDID_LENGTH; in drm_do_get_edid()
1993 if (valid_extensions != edid[0x7e]) { in drm_do_get_edid()
1996 connector_bad_edid(connector, edid, edid[0x7e] + 1); in drm_do_get_edid()
2004 for (i = 0; i <= edid[0x7e]; i++) { in drm_do_get_edid()
2005 u8 *block = edid + i * EDID_LENGTH; in drm_do_get_edid()
2017 kfree(edid); in drm_do_get_edid()
2018 edid = new; in drm_do_get_edid()
2021 return (struct edid *)edid; in drm_do_get_edid()
2024 connector_bad_edid(connector, edid, 1); in drm_do_get_edid()
2026 kfree(edid); in drm_do_get_edid()
2047 * drm_get_edid - get EDID data, if available
2051 * Poke the given I2C channel to grab EDID data if possible. If found,
2054 * Return: Pointer to valid EDID or NULL if we couldn't find any.
2056 struct edid *drm_get_edid(struct drm_connector *connector, in drm_get_edid()
2059 struct edid *edid; in drm_get_edid() local
2067 edid = drm_do_get_edid(connector, drm_do_probe_ddc_edid, adapter); in drm_get_edid()
2068 drm_connector_update_edid_property(connector, edid); in drm_get_edid()
2069 return edid; in drm_get_edid()
2074 * drm_get_edid_switcheroo - get EDID data for a vga_switcheroo output
2080 * switch DDC to the GPU which is retrieving EDID.
2082 * Return: Pointer to valid EDID or %NULL if we couldn't find any.
2084 struct edid *drm_get_edid_switcheroo(struct drm_connector *connector, in drm_get_edid_switcheroo()
2088 struct edid *edid; in drm_get_edid_switcheroo() local
2091 edid = drm_get_edid(connector, adapter); in drm_get_edid_switcheroo()
2094 return edid; in drm_get_edid_switcheroo()
2099 * drm_edid_duplicate - duplicate an EDID and the extensions
2100 * @edid: EDID to duplicate
2102 * Return: Pointer to duplicated EDID or NULL on allocation failure.
2104 struct edid *drm_edid_duplicate(const struct edid *edid) in drm_edid_duplicate() argument
2106 return kmemdup(edid, (edid->extensions + 1) * EDID_LENGTH, GFP_KERNEL); in drm_edid_duplicate()
2110 /*** EDID parsing ***/
2113 * edid_vendor - match a string against EDID's obfuscated vendor field
2114 * @edid: EDID to match
2117 * Returns true if @vendor is in @edid, false otherwise
2119 static bool edid_vendor(const struct edid *edid, const char *vendor) in edid_vendor() argument
2123 edid_vendor[0] = ((edid->mfg_id[0] & 0x7c) >> 2) + '@'; in edid_vendor()
2124 edid_vendor[1] = (((edid->mfg_id[0] & 0x3) << 3) | in edid_vendor()
2125 ((edid->mfg_id[1] & 0xe0) >> 5)) + '@'; in edid_vendor()
2126 edid_vendor[2] = (edid->mfg_id[1] & 0x1f) + '@'; in edid_vendor()
2132 * edid_get_quirks - return quirk flags for a given EDID
2133 * @edid: EDID to process
2137 static u32 edid_get_quirks(const struct edid *edid) in edid_get_quirks() argument
2145 if (edid_vendor(edid, quirk->vendor) && in edid_get_quirks()
2146 (EDID_PRODUCT_ID(edid) == quirk->product_id)) in edid_get_quirks()
2296 struct edid *edid = (struct edid *)raw_edid; in drm_for_each_detailed_block() local
2298 if (edid == NULL) in drm_for_each_detailed_block()
2302 cb(&(edid->detailed_timings[i]), closure); in drm_for_each_detailed_block()
2332 /* EDID 1.4 defines this explicitly. For EDID 1.3, we guess, badly. */
2334 drm_monitor_supports_rb(struct edid *edid) in drm_monitor_supports_rb() argument
2336 if (edid->revision >= 4) { in drm_monitor_supports_rb()
2339 drm_for_each_detailed_block((u8 *)edid, is_rb, &ret); in drm_monitor_supports_rb()
2343 return ((edid->input & DRM_EDID_INPUT_DIGITAL) != 0); in drm_monitor_supports_rb()
2360 drm_gtf2_hbreak(struct edid *edid) in drm_gtf2_hbreak() argument
2364 drm_for_each_detailed_block((u8 *)edid, find_gtf2, &r); in drm_gtf2_hbreak()
2369 drm_gtf2_2c(struct edid *edid) in drm_gtf2_2c() argument
2373 drm_for_each_detailed_block((u8 *)edid, find_gtf2, &r); in drm_gtf2_2c()
2378 drm_gtf2_m(struct edid *edid) in drm_gtf2_m() argument
2382 drm_for_each_detailed_block((u8 *)edid, find_gtf2, &r); in drm_gtf2_m()
2387 drm_gtf2_k(struct edid *edid) in drm_gtf2_k() argument
2391 drm_for_each_detailed_block((u8 *)edid, find_gtf2, &r); in drm_gtf2_k()
2396 drm_gtf2_2j(struct edid *edid) in drm_gtf2_2j() argument
2400 drm_for_each_detailed_block((u8 *)edid, find_gtf2, &r); in drm_gtf2_2j()
2406 * @edid: EDID block to scan
2408 static int standard_timing_level(struct edid *edid) in standard_timing_level() argument
2410 if (edid->revision >= 2) { in standard_timing_level()
2411 if (edid->revision >= 4 && (edid->features & DRM_EDID_FEATURE_DEFAULT_GTF)) in standard_timing_level()
2413 if (drm_gtf2_hbreak(edid)) in standard_timing_level()
2415 if (edid->features & DRM_EDID_FEATURE_DEFAULT_GTF) in standard_timing_level()
2443 * @connector: connector of for the EDID block
2444 * @edid: EDID block to scan
2451 drm_mode_std(struct drm_connector *connector, struct edid *edid, in drm_mode_std() argument
2462 int timing_level = standard_timing_level(edid); in drm_mode_std()
2467 /* According to the EDID spec, the hdisplay = hsize * 8 + 248 */ in drm_mode_std()
2473 if (edid->revision < 3) in drm_mode_std()
2516 if (drm_monitor_supports_rb(edid)) { in drm_mode_std()
2542 if (drm_mode_hsync(mode) > drm_gtf2_hbreak(edid)) { in drm_mode_std()
2546 drm_gtf2_m(edid), in drm_mode_std()
2547 drm_gtf2_2c(edid), in drm_mode_std()
2548 drm_gtf2_k(edid), in drm_mode_std()
2549 drm_gtf2_2j(edid)); in drm_mode_std()
2561 * EDID is delightfully ambiguous about how interlaced modes are to be
2603 * drm_mode_detailed - create a new mode from an EDID detailed timing section
2605 * @edid: EDID block
2606 * @timing: EDID detailed timing info
2609 * An EDID detailed timing block contains enough info for us to create and
2613 struct edid *edid, in drm_mode_detailed() argument
2701 mode->width_mm = edid->width_cm * 10; in drm_mode_detailed()
2702 mode->height_mm = edid->height_cm * 10; in drm_mode_detailed()
2713 struct edid *edid, u8 *t) in mode_in_hsync_range() argument
2718 if (edid->revision >= 4) in mode_in_hsync_range()
2721 if (edid->revision >= 4) in mode_in_hsync_range()
2730 struct edid *edid, u8 *t) in mode_in_vsync_range() argument
2735 if (edid->revision >= 4) in mode_in_vsync_range()
2738 if (edid->revision >= 4) in mode_in_vsync_range()
2746 range_pixel_clock(struct edid *edid, u8 *t) in range_pixel_clock() argument
2753 if (edid->revision >= 4 && t[10] == 0x04) in range_pixel_clock()
2761 mode_in_range(const struct drm_display_mode *mode, struct edid *edid, in mode_in_range() argument
2767 if (!mode_in_hsync_range(mode, edid, t)) in mode_in_range()
2770 if (!mode_in_vsync_range(mode, edid, t)) in mode_in_range()
2773 if ((max_clock = range_pixel_clock(edid, t))) in mode_in_range()
2778 if (edid->revision >= 4 && t[10] == 0x04) in mode_in_range()
2782 if (mode_is_rb(mode) && !drm_monitor_supports_rb(edid)) in mode_in_range()
2807 drm_dmt_modes_for_range(struct drm_connector *connector, struct edid *edid, in drm_dmt_modes_for_range() argument
2815 if (mode_in_range(drm_dmt_modes + i, edid, timing) && in drm_dmt_modes_for_range()
2842 drm_gtf_modes_for_range(struct drm_connector *connector, struct edid *edid, in drm_gtf_modes_for_range() argument
2857 if (!mode_in_range(newmode, edid, timing) || in drm_gtf_modes_for_range()
2871 drm_cvt_modes_for_range(struct drm_connector *connector, struct edid *edid, in drm_cvt_modes_for_range() argument
2877 bool rb = drm_monitor_supports_rb(edid); in drm_cvt_modes_for_range()
2887 if (!mode_in_range(newmode, edid, timing) || in drm_cvt_modes_for_range()
2911 closure->edid, in do_inferred_modes()
2914 if (!version_greater(closure->edid, 1, 1)) in do_inferred_modes()
2921 closure->edid, in do_inferred_modes()
2925 if (!version_greater(closure->edid, 1, 3)) in do_inferred_modes()
2929 closure->edid, in do_inferred_modes()
2939 add_inferred_modes(struct drm_connector *connector, struct edid *edid) in add_inferred_modes() argument
2943 .edid = edid, in add_inferred_modes()
2946 if (version_greater(edid, 1, 0)) in add_inferred_modes()
2947 drm_for_each_detailed_block((u8 *)edid, do_inferred_modes, in add_inferred_modes()
2994 * add_established_modes - get est. modes from EDID and add them
2996 * @edid: EDID block to scan
2998 * Each EDID block contains a bitmap of the supported "established modes" list
3002 add_established_modes(struct drm_connector *connector, struct edid *edid) in add_established_modes() argument
3005 unsigned long est_bits = edid->established_timings.t1 | in add_established_modes()
3006 (edid->established_timings.t2 << 8) | in add_established_modes()
3007 ((edid->established_timings.mfg_rsvd & 0x80) << 9); in add_established_modes()
3011 .edid = edid, in add_established_modes()
3026 if (version_greater(edid, 1, 0)) in add_established_modes()
3027 drm_for_each_detailed_block((u8 *)edid, in add_established_modes()
3039 struct edid *edid = closure->edid; in do_standard_modes() local
3049 newmode = drm_mode_std(connector, edid, std); in do_standard_modes()
3058 * add_standard_modes - get std. modes from EDID and add them
3060 * @edid: EDID block to scan
3063 * GTF or CVT. Grab them from @edid and add them to the list.
3066 add_standard_modes(struct drm_connector *connector, struct edid *edid) in add_standard_modes() argument
3071 .edid = edid, in add_standard_modes()
3077 newmode = drm_mode_std(connector, edid, in add_standard_modes()
3078 &edid->standard_timings[i]); in add_standard_modes()
3085 if (version_greater(edid, 1, 0)) in add_standard_modes()
3086 drm_for_each_detailed_block((u8 *)edid, do_standard_modes, in add_standard_modes()
3158 add_cvt_modes(struct drm_connector *connector, struct edid *edid) in add_cvt_modes() argument
3162 .edid = edid, in add_cvt_modes()
3165 if (version_greater(edid, 1, 2)) in add_cvt_modes()
3166 drm_for_each_detailed_block((u8 *)edid, do_cvt_mode, &closure); in add_cvt_modes()
3185 closure->edid, timing, in do_detailed_mode()
3208 * @edid: EDID block to scan
3212 add_detailed_modes(struct drm_connector *connector, struct edid *edid, in add_detailed_modes() argument
3217 .edid = edid, in add_detailed_modes()
3222 if (closure.preferred && !version_greater(edid, 1, 3)) in add_detailed_modes()
3224 (edid->features & DRM_EDID_FEATURE_PREFERRED_TIMING); in add_detailed_modes()
3226 drm_for_each_detailed_block((u8 *)edid, do_detailed_mode, &closure); in add_detailed_modes()
3246 * Search EDID for CEA extension block.
3248 static u8 *drm_find_edid_extension(const struct edid *edid, in drm_find_edid_extension() argument
3254 /* No EDID or EDID extensions */ in drm_find_edid_extension()
3255 if (edid == NULL || edid->extensions == 0) in drm_find_edid_extension()
3259 for (i = *ext_index; i < edid->extensions; i++) { in drm_find_edid_extension()
3260 edid_ext = (u8 *)edid + EDID_LENGTH * (i + 1); in drm_find_edid_extension()
3265 if (i >= edid->extensions) in drm_find_edid_extension()
3274 static u8 *drm_find_displayid_extension(const struct edid *edid, in drm_find_displayid_extension() argument
3278 u8 *displayid = drm_find_edid_extension(edid, DISPLAYID_EXT, ext_index); in drm_find_displayid_extension()
3285 /* EDID extensions block checksum isn't for us */ in drm_find_displayid_extension()
3299 static u8 *drm_find_cea_extension(const struct edid *edid) in drm_find_cea_extension() argument
3310 cea = drm_find_edid_extension(edid, CEA_EXT, &ext_index); in drm_find_cea_extension()
3317 displayid = drm_find_displayid_extension(edid, &length, &idx, in drm_find_cea_extension()
3591 add_alternate_cea_modes(struct drm_connector *connector, struct edid *edid) in add_alternate_cea_modes() argument
3599 if (!drm_find_cea_extension(edid)) in add_alternate_cea_modes()
4114 /* DisplayID CTA extension blocks and top-level CEA EDID in cea_db_offsets()
4124 * CEA EDID block defines byte 2 as: in cea_db_offsets()
4269 add_cea_modes(struct drm_connector *connector, struct edid *edid) in add_cea_modes() argument
4271 const u8 *cea = drm_find_cea_extension(edid); in add_cea_modes()
4296 /* Add 4:2:0(only) modes present in EDID */ in add_cea_modes()
4447 static int get_monitor_name(struct edid *edid, char name[13]) in get_monitor_name() argument
4452 if (!edid || !name) in get_monitor_name()
4455 drm_for_each_detailed_block((u8 *)edid, monitor_name, &edid_name); in get_monitor_name()
4467 * drm_edid_get_monitor_name - fetch the monitor name from the edid
4468 * @edid: monitor EDID information
4473 void drm_edid_get_monitor_name(struct edid *edid, char *name, int bufsize) in drm_edid_get_monitor_name() argument
4481 name_length = min(get_monitor_name(edid, buf), bufsize - 1); in drm_edid_get_monitor_name()
4500 * drm_edid_to_eld - build ELD from EDID
4502 * @edid: EDID to parse
4504 * Fill the ELD (EDID-Like Data) buffer for passing to the audio driver. The
4507 static void drm_edid_to_eld(struct drm_connector *connector, struct edid *edid) in drm_edid_to_eld() argument
4518 if (!edid) in drm_edid_to_eld()
4521 cea = drm_find_cea_extension(edid); in drm_edid_to_eld()
4527 mnl = get_monitor_name(edid, &eld[DRM_ELD_MONITOR_NAME_STRING]); in drm_edid_to_eld()
4535 eld[DRM_ELD_MANUFACTURER_NAME0] = edid->mfg_id[0]; in drm_edid_to_eld()
4536 eld[DRM_ELD_MANUFACTURER_NAME1] = edid->mfg_id[1]; in drm_edid_to_eld()
4537 eld[DRM_ELD_PRODUCT_CODE0] = edid->prod_code[0]; in drm_edid_to_eld()
4538 eld[DRM_ELD_PRODUCT_CODE1] = edid->prod_code[1]; in drm_edid_to_eld()
4593 * drm_edid_to_sad - extracts SADs from EDID
4594 * @edid: EDID to parse
4597 * Looks for CEA EDID block and extracts SADs (Short Audio Descriptors) from it.
4603 int drm_edid_to_sad(struct edid *edid, struct cea_sad **sads) in drm_edid_to_sad() argument
4609 cea = drm_find_cea_extension(edid); in drm_edid_to_sad()
4654 * drm_edid_to_speaker_allocation - extracts Speaker Allocation Data Blocks from EDID
4655 * @edid: EDID to parse
4658 * Looks for CEA EDID block and extracts the Speaker Allocation Data Block from it.
4665 int drm_edid_to_speaker_allocation(struct edid *edid, u8 **sadb) in drm_edid_to_speaker_allocation() argument
4671 cea = drm_find_cea_extension(edid); in drm_edid_to_speaker_allocation()
4737 * Convert raw EDID values to millisecond. in drm_av_sync_delay()
4751 * @edid: monitor EDID information
4755 * Drivers that have added the modes parsed from EDID to drm_display_info
4760 bool drm_detect_hdmi_monitor(struct edid *edid) in drm_detect_hdmi_monitor() argument
4766 edid_ext = drm_find_cea_extension(edid); in drm_detect_hdmi_monitor()
4788 * @edid: EDID block to scan
4794 * audio' is not defined in EDID.
4798 bool drm_detect_monitor_audio(struct edid *edid) in drm_detect_monitor_audio() argument
4805 edid_ext = drm_find_cea_extension(edid); in drm_detect_monitor_audio()
4891 * * Availability of a HF-VSDB block in EDID (check) in drm_parse_hdmi_forum_vsdb()
5001 const struct edid *edid) in drm_parse_cea_ext() argument
5007 edid_ext = drm_find_cea_extension(edid); in drm_parse_cea_ext()
5065 const struct edid *edid) in drm_get_monitor_range() argument
5069 if (!version_greater(edid, 1, 1)) in drm_get_monitor_range()
5072 drm_for_each_detailed_block((u8 *)edid, get_monitor_range, in drm_get_monitor_range()
5080 /* A connector has no EDID information, so we've got no EDID to compute quirks from. Reset
5081 * all of the values which would have been set from EDID
5105 u32 drm_add_display_info(struct drm_connector *connector, const struct edid *edid) in drm_add_display_info() argument
5109 u32 quirks = edid_get_quirks(edid); in drm_add_display_info()
5113 info->width_mm = edid->width_cm * 10; in drm_add_display_info()
5114 info->height_mm = edid->height_cm * 10; in drm_add_display_info()
5118 drm_get_monitor_range(connector, edid); in drm_add_display_info()
5122 if (edid->revision < 3) in drm_add_display_info()
5125 if (!(edid->input & DRM_EDID_INPUT_DIGITAL)) in drm_add_display_info()
5129 drm_parse_cea_ext(connector, edid); in drm_add_display_info()
5132 * Digital sink with "DFP 1.x compliant TMDS" according to EDID 1.3? in drm_add_display_info()
5134 * For such displays, the DFP spec 1.0, section 3.10 "EDID support" in drm_add_display_info()
5135 * tells us to assume 8 bpc color depth if the EDID doesn't have in drm_add_display_info()
5138 if (info->bpc == 0 && edid->revision == 3 && in drm_add_display_info()
5139 edid->input & DRM_EDID_DIGITAL_DFP_1_X) { in drm_add_display_info()
5146 if (edid->revision < 4) in drm_add_display_info()
5149 switch (edid->input & DRM_EDID_DIGITAL_DEPTH_MASK) { in drm_add_display_info()
5174 DRM_DEBUG("%s: Assigning EDID-1.4 digital sink color depth as %d bpc.\n", in drm_add_display_info()
5177 if (edid->features & DRM_EDID_FEATURE_RGB_YCRCB444) in drm_add_display_info()
5179 if (edid->features & DRM_EDID_FEATURE_RGB_YCRCB422) in drm_add_display_info()
5282 struct edid *edid) in add_displayid_detailed_modes() argument
5291 displayid = drm_find_displayid_extension(edid, &length, &idx, in add_displayid_detailed_modes()
5310 * drm_add_edid_modes - add modes from EDID data, if available
5312 * @edid: EDID data
5316 * can be derived from the edid.
5320 int drm_add_edid_modes(struct drm_connector *connector, struct edid *edid) in drm_add_edid_modes() argument
5325 if (edid == NULL) { in drm_add_edid_modes()
5329 if (!drm_edid_is_valid(edid)) { in drm_add_edid_modes()
5331 drm_warn(connector->dev, "%s: EDID invalid.\n", in drm_add_edid_modes()
5336 drm_edid_to_eld(connector, edid); in drm_add_edid_modes()
5343 quirks = drm_add_display_info(connector, edid); in drm_add_edid_modes()
5346 * EDID spec says modes should be preferred in this order: in drm_add_edid_modes()
5359 num_modes += add_detailed_modes(connector, edid, quirks); in drm_add_edid_modes()
5360 num_modes += add_cvt_modes(connector, edid); in drm_add_edid_modes()
5361 num_modes += add_standard_modes(connector, edid); in drm_add_edid_modes()
5362 num_modes += add_established_modes(connector, edid); in drm_add_edid_modes()
5363 num_modes += add_cea_modes(connector, edid); in drm_add_edid_modes()
5364 num_modes += add_alternate_cea_modes(connector, edid); in drm_add_edid_modes()
5365 num_modes += add_displayid_detailed_modes(connector, edid); in drm_add_edid_modes()
5366 if (edid->features & DRM_EDID_FEATURE_DEFAULT_GTF) in drm_add_edid_modes()
5367 num_modes += add_inferred_modes(connector, edid); in drm_add_edid_modes()
5389 * drm_add_modes_noedid - add modes for the connectors without EDID
5963 const struct edid *edid) in drm_update_tile_info() argument
5971 displayid = drm_find_displayid_extension(edid, &length, &idx, in drm_update_tile_info()