Lines Matching refs:set
516 int drm_crtc_helper_set_config(struct drm_mode_set *set, in drm_crtc_helper_set_config() argument
534 BUG_ON(!set); in drm_crtc_helper_set_config()
535 BUG_ON(!set->crtc); in drm_crtc_helper_set_config()
536 BUG_ON(!set->crtc->helper_private); in drm_crtc_helper_set_config()
539 BUG_ON(!set->mode && set->fb); in drm_crtc_helper_set_config()
540 BUG_ON(set->fb && set->num_connectors == 0); in drm_crtc_helper_set_config()
542 crtc_funcs = set->crtc->helper_private; in drm_crtc_helper_set_config()
544 dev = set->crtc->dev; in drm_crtc_helper_set_config()
547 if (!set->mode) in drm_crtc_helper_set_config()
548 set->fb = NULL; in drm_crtc_helper_set_config()
550 if (set->fb) { in drm_crtc_helper_set_config()
552 set->crtc->base.id, set->crtc->name, in drm_crtc_helper_set_config()
553 set->fb->base.id, in drm_crtc_helper_set_config()
554 (int)set->num_connectors, set->x, set->y); in drm_crtc_helper_set_config()
557 set->crtc->base.id, set->crtc->name); in drm_crtc_helper_set_config()
558 drm_crtc_helper_disable(set->crtc); in drm_crtc_helper_set_config()
596 save_set.crtc = set->crtc; in drm_crtc_helper_set_config()
597 save_set.mode = &set->crtc->mode; in drm_crtc_helper_set_config()
598 save_set.x = set->crtc->x; in drm_crtc_helper_set_config()
599 save_set.y = set->crtc->y; in drm_crtc_helper_set_config()
600 save_set.fb = set->crtc->primary->fb; in drm_crtc_helper_set_config()
604 if (set->crtc->primary->fb != set->fb) { in drm_crtc_helper_set_config()
606 if (set->crtc->primary->fb == NULL) { in drm_crtc_helper_set_config()
609 } else if (set->fb->format != set->crtc->primary->fb->format) { in drm_crtc_helper_set_config()
615 if (set->x != set->crtc->x || set->y != set->crtc->y) in drm_crtc_helper_set_config()
618 if (!drm_mode_equal(set->mode, &set->crtc->mode)) { in drm_crtc_helper_set_config()
620 drm_mode_debug_printmodeline(&set->crtc->mode); in drm_crtc_helper_set_config()
621 drm_mode_debug_printmodeline(set->mode); in drm_crtc_helper_set_config()
628 for (ro = 0; ro < set->num_connectors; ro++) { in drm_crtc_helper_set_config()
629 if (set->connectors[ro]->encoder) in drm_crtc_helper_set_config()
631 drm_connector_get(set->connectors[ro]); in drm_crtc_helper_set_config()
641 for (ro = 0; ro < set->num_connectors; ro++) { in drm_crtc_helper_set_config()
642 if (set->connectors[ro] == connector) { in drm_crtc_helper_set_config()
687 if (connector->encoder->crtc == set->crtc) in drm_crtc_helper_set_config()
692 for (ro = 0; ro < set->num_connectors; ro++) { in drm_crtc_helper_set_config()
693 if (set->connectors[ro] == connector) in drm_crtc_helper_set_config()
694 new_crtc = set->crtc; in drm_crtc_helper_set_config()
725 if (drm_helper_crtc_in_use(set->crtc)) { in drm_crtc_helper_set_config()
728 drm_mode_debug_printmodeline(set->mode); in drm_crtc_helper_set_config()
729 set->crtc->primary->fb = set->fb; in drm_crtc_helper_set_config()
730 if (!drm_crtc_helper_set_mode(set->crtc, set->mode, in drm_crtc_helper_set_config()
731 set->x, set->y, in drm_crtc_helper_set_config()
734 set->crtc->base.id, set->crtc->name); in drm_crtc_helper_set_config()
735 set->crtc->primary->fb = save_set.fb; in drm_crtc_helper_set_config()
740 for (i = 0; i < set->num_connectors; i++) { in drm_crtc_helper_set_config()
741 DRM_DEBUG_KMS("\t[CONNECTOR:%d:%s] set DPMS on\n", set->connectors[i]->base.id, in drm_crtc_helper_set_config()
742 set->connectors[i]->name); in drm_crtc_helper_set_config()
743 set->connectors[i]->funcs->dpms(set->connectors[i], DRM_MODE_DPMS_ON); in drm_crtc_helper_set_config()
748 set->crtc->x = set->x; in drm_crtc_helper_set_config()
749 set->crtc->y = set->y; in drm_crtc_helper_set_config()
750 set->crtc->primary->fb = set->fb; in drm_crtc_helper_set_config()
751 ret = crtc_funcs->mode_set_base(set->crtc, in drm_crtc_helper_set_config()
752 set->x, set->y, save_set.fb); in drm_crtc_helper_set_config()
754 set->crtc->x = save_set.x; in drm_crtc_helper_set_config()
755 set->crtc->y = save_set.y; in drm_crtc_helper_set_config()
756 set->crtc->primary->fb = save_set.fb; in drm_crtc_helper_set_config()
781 for (ro = 0; ro < set->num_connectors; ro++) { in drm_crtc_helper_set_config()
782 if (set->connectors[ro]->encoder) in drm_crtc_helper_set_config()
784 drm_connector_put(set->connectors[ro]); in drm_crtc_helper_set_config()
1010 struct drm_mode_set set = { in drm_helper_force_disable_all() local
1014 ret = drm_mode_set_config_internal(&set); in drm_helper_force_disable_all()