Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f41c2581 authored by Laurent Pinchart's avatar Laurent Pinchart Committed by Dave Airlie
Browse files

drm/doc: Document drm_add_modes_noedid() usage



And fix a spelling mistake.

Signed-off-by: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
parent da9df2f4
Loading
Loading
Loading
Loading
+19 −5
Original line number Original line Diff line number Diff line
@@ -1948,9 +1948,15 @@ void intel_crt_init(struct drm_device *dev)
            <methodname>get_modes</methodname> helper operation.
            <methodname>get_modes</methodname> helper operation.
          </para>
          </para>
         <para>
         <para>
            The function filters out modes larger than
            If the helper operation returns no mode, and if the connector status
            is connector_status_connected, standard VESA DMT modes up to
            1024x768 are automatically added to the modes list by a call to
            <function>drm_add_modes_noedid</function>.
          </para>
          <para>
            The function then filters out modes larger than
            <parameter>max_width</parameter> and <parameter>max_height</parameter>
            <parameter>max_width</parameter> and <parameter>max_height</parameter>
            if specified. It then calls the optional connector
            if specified. It finally calls the optional connector
            <methodname>mode_valid</methodname> helper operation for each mode in
            <methodname>mode_valid</methodname> helper operation for each mode in
            the probed list to check whether the mode is valid for the connector.
            the probed list to check whether the mode is valid for the connector.
          </para>
          </para>
@@ -2090,11 +2096,19 @@ void intel_crt_init(struct drm_device *dev)
          <synopsis>int (*get_modes)(struct drm_connector *connector);</synopsis>
          <synopsis>int (*get_modes)(struct drm_connector *connector);</synopsis>
          <para>
          <para>
            Fill the connector's <structfield>probed_modes</structfield> list
            Fill the connector's <structfield>probed_modes</structfield> list
            by parsing EDID data with <function>drm_add_edid_modes</function> or
            by parsing EDID data with <function>drm_add_edid_modes</function>,
            calling <function>drm_mode_probed_add</function> directly for every
            adding standard VESA DMT modes with <function>drm_add_modes_noedid</function>,
            or calling <function>drm_mode_probed_add</function> directly for every
            supported mode and return the number of modes it has detected. This
            supported mode and return the number of modes it has detected. This
            operation is mandatory.
            operation is mandatory.
          </para>
          </para>
          <para>
            Note that the caller function will automatically add standard VESA
            DMT modes up to 1024x768 if the <methodname>get_modes</methodname>
            helper operation returns no mode and if the connector status is
            connector_status_connected. There is no need to call
            <function>drm_add_edid_modes</function> manually in that case.
          </para>
          <para>
          <para>
            When adding modes manually the driver creates each mode with a call to
            When adding modes manually the driver creates each mode with a call to
            <function>drm_mode_create</function> and must fill the following fields.
            <function>drm_mode_create</function> and must fill the following fields.
@@ -2292,7 +2306,7 @@ void intel_crt_init(struct drm_device *dev)
            <function>drm_helper_probe_single_connector_modes</function>.
            <function>drm_helper_probe_single_connector_modes</function>.
          </para>
          </para>
          <para>
          <para>
            When parsing EDID data, <function>drm_add_edid_modes</function> fill the
            When parsing EDID data, <function>drm_add_edid_modes</function> fills the
            connector <structfield>display_info</structfield>
            connector <structfield>display_info</structfield>
            <structfield>width_mm</structfield> and
            <structfield>width_mm</structfield> and
            <structfield>height_mm</structfield> fields. When creating modes
            <structfield>height_mm</structfield> fields. When creating modes