aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVille Syrjälä <ville.syrjala@linux.intel.com>2015-12-10 16:13:57 -0500
committerDaniel Vetter <daniel.vetter@ffwll.ch>2015-12-11 03:35:16 -0500
commit5dec293b2434783a6924571df5239e10ab5e9331 (patch)
treec6ca382970b582b8a89643470dfccb208c1422a0
parent0e8578c996a33c8da9c28f8ed2d1be68694070ee (diff)
drm: Expand the drm_helper_probe_single_connector_modes() docs
Describe the procedure that drm_helper_probe_single_connector_modes() uses to do it's work in the kernel-doc comment. Caveat: Looks like crap and trying to reverse engineer the documentation tools is not something I want to do. Suggested-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1449782037-19722-3-git-send-email-ville.syrjala@linux.intel.com
-rw-r--r--drivers/gpu/drm/drm_probe_helper.c49
1 files changed, 37 insertions, 12 deletions
diff --git a/drivers/gpu/drm/drm_probe_helper.c b/drivers/gpu/drm/drm_probe_helper.c
index 13d178e6981b..e714b5a7955f 100644
--- a/drivers/gpu/drm/drm_probe_helper.c
+++ b/drivers/gpu/drm/drm_probe_helper.c
@@ -144,18 +144,43 @@ EXPORT_SYMBOL(drm_kms_helper_poll_enable_locked);
144 * @connector vfunc for drivers that use the CRTC helpers for output mode 144 * @connector vfunc for drivers that use the CRTC helpers for output mode
145 * filtering and detection. 145 * filtering and detection.
146 * 146 *
147 * If the helper operation returns no mode, and if the connector status is 147 * The basic procedure is as follows
148 * connector_status_connected, standard VESA DMT modes up to 1024x768 are 148 *
149 * automatically added to the modes list by a call to 149 * 1. All modes currently on the connector's modes list are marked as stale
150 * drm_add_modes_noedid(). 150 *
151 * 151 * 2. New modes are added to the connector's probed_modes list with
152 * The function then filters out modes larger than @maxX and maxY if specified. 152 * drm_mode_probed_add(). New modes start their life with status as OK.
153 * It finally calls the optional connector ->mode_valid() helper operation for each 153 * Modes are added from a single source using the following priority order.
154 * mode in the probed list to check whether the mode is valid for the connector. 154 *
155 * 155 * - debugfs 'override_edid' (used for testing only)
156 * Compared to drm_helper_probe_single_connector_modes_nomerge() this function 156 * - firmware EDID (drm_load_edid_firmware())
157 * merged the mode bits for the preferred mode, as a hack to work around some 157 * - connector helper ->get_modes() vfunc
158 * quirky issues on funky hardware. 158 * - if the connector status is connector_status_connected, standard
159 * VESA DMT modes up to 1024x768 are automatically added
160 * (drm_add_modes_noedid())
161 *
162 * Finally modes specified via the kernel command line (video=...) are
163 * added in addition to what the earlier probes produced
164 * (drm_helper_probe_add_cmdline_mode()). These modes are generated
165 * using the VESA GTF/CVT formulas.
166 *
167 * 3. Modes are moved from the probed_modes list to the modes list. Potential
168 * duplicates are merged together (see drm_mode_connector_list_update()).
169 * After this step the probed_modes list will be empty again.
170 *
171 * 4. Any non-stale mode on the modes list then undergoes validation
172 *
173 * - drm_mode_validate_basic() performs basic sanity checks
174 * - drm_mode_validate_size() filters out modes larger than @maxX and @maxY
175 * (if specified)
176 * - drm_mode_validate_flag() checks the modes againt basic connector
177 * capabilites (interlace_allowed,doublescan_allowed,stereo_allowed)
178 * - the optional connector ->mode_valid() helper can perform driver and/or
179 * hardware specific checks
180 *
181 * 5. Any mode whose status is not OK is pruned from the connector's modes list,
182 * accompanied by a debug message indicating the reason for the mode's
183 * rejection (see drm_mode_prune_invalid()).
159 * 184 *
160 * Returns: 185 * Returns:
161 * The number of modes found on @connector. 186 * The number of modes found on @connector.