Lines Matching refs:mode

77 	struct drm_display_mode *mode;
82 list_for_each_entry(mode, struct drm_display_mode, &connector->modes, head) {
83 if ((mode->flags & DRM_MODE_FLAG_INTERLACE) &&
85 mode->status = MODE_NO_INTERLACE;
86 if ((mode->flags & DRM_MODE_FLAG_DBLSCAN) &&
88 mode->status = MODE_NO_DBLESCAN;
101 * Caller must hold mode config lock.
120 struct drm_display_mode *mode;
130 list_for_each_entry(mode, struct drm_display_mode, &connector->modes, head)
131 mode->status = MODE_UNVERIFIED;
180 list_for_each_entry(mode, struct drm_display_mode, &connector->modes, head){
181 if (mode->status == MODE_OK)
182 mode->status = connector_funcs->mode_valid(connector,
183 mode);
192 list_for_each_entry(mode, struct drm_display_mode, &connector->modes, head)
193 mode->vrefresh = drm_mode_vrefresh(mode);
199 list_for_each_entry(mode, struct drm_display_mode, &connector->modes, head){
200 drm_mode_set_crtcinfo(mode, CRTC_INTERLACE_HALVE_V);
201 drm_mode_debug_printmodeline(mode);
213 * Caller must hold mode config lock.
235 * Caller must hold mode config lock.
268 * Caller must hold mode config lock.
362 * drm_crtc_set_mode - set a mode
364 * @mode: mode to use
365 * @x: width of mode
366 * @y: height of mode
370 * Caller must hold mode config lock.
372 * Try to set @mode on @crtc. Give @crtc and its associated connectors a chance
373 * to fixup or reject the mode prior to trying to set it. This is an internal
378 * drm_crtc_helper_set_config() helper function to drive the mode setting
382 * True if the mode was set successfully, or false otherwise.
385 struct drm_display_mode *mode,
401 adjusted_mode = drm_mode_duplicate(dev, mode);
406 saved_mode = crtc->mode;
410 /* Update crtc values up front so the driver can rely on them for mode
413 crtc->mode = *mode;
417 /* Pass our mode to the connectors and the CRTC to give them a chance to
419 * a chance to reject the mode entirely.
426 if (!(ret = encoder_funcs->mode_fixup(encoder, mode,
433 if (!(ret = crtc_funcs->mode_fixup(crtc, mode, adjusted_mode))) {
439 /* Prepare the encoders and CRTCs before setting the mode. */
456 ret = !crtc_funcs->mode_set(crtc, mode, adjusted_mode, x, y, old_fb);
467 mode->base.id, mode->name);
469 encoder_funcs->mode_set(encoder, mode, adjusted_mode);
485 /* Store real post-adjustment hardware mode. */
499 crtc->mode = saved_mode;
533 * @set: mode set configuration
536 * Caller must hold mode config lock.
541 * kernel mode setting with the crtc helper functions and the assorted
553 bool mode_changed = false; /* if true do a full mode set */
569 BUG_ON(!set->mode && set->fb);
574 if (!set->mode)
630 save_set.mode = &set->crtc->mode;
638 /* If we have no fb then treat it as a full mode set */
640 DRM_DEBUG_KMS("crtc has no fb, full mode set\n");
654 if (set->mode && !drm_mode_equal(set->mode, &set->crtc->mode)) {
655 DRM_DEBUG_KMS("modes are different, full mode set\n");
656 drm_mode_debug_printmodeline(&set->crtc->mode);
657 drm_mode_debug_printmodeline(set->mode);
678 DRM_DEBUG_KMS("connector dpms not on, full mode switch\n");
686 DRM_DEBUG_KMS("encoder changed, full mode switch\n");
724 DRM_DEBUG_KMS("crtc changed, full mode switch\n");
745 DRM_DEBUG_KMS("attempting to set mode from"
747 drm_mode_debug_printmodeline(set->mode);
750 if (!drm_crtc_helper_set_mode(set->crtc, set->mode,
753 DRM_ERROR("failed to set mode on [CRTC:%d]\n",
806 !drm_crtc_helper_set_mode(save_set.crtc, save_set.mode, save_set.x,
846 * @mode DPMS mode
853 void drm_helper_connector_dpms(struct drm_connector *connector, int mode)
859 if (mode == connector->dpms)
863 connector->dpms = mode;
866 if (mode < old_dpms) {
882 if (mode > old_dpms) {
932 ret = drm_crtc_helper_set_mode(crtc, &crtc->mode,
936 DRM_ERROR("failed to set mode on crtc %p\n", (void *)crtc);