/** * xe_display_driver_probe_defer - Detect if we need to wait for other drivers * early on * @pdev: PCI device * * Note: This is called before xe or display device creation. * * Returns: true if probe needs to be deferred, false otherwise
*/ bool xe_display_driver_probe_defer(struct pci_dev *pdev)
{ if (!xe_modparam.probe_display) return 0;
return intel_display_driver_probe_defer(pdev);
}
/** * xe_display_driver_set_hooks - Add driver flags and hooks for display * @driver: DRM device driver * * Set features and function hooks in @driver that are needed for driving the * display IP. This sets the driver's capability of driving display, regardless * if the device has it enabled * * Note: This is called before xe or display device creation.
*/ void xe_display_driver_set_hooks(struct drm_driver *driver)
{ if (!xe_modparam.probe_display) return;
/* Early display init.. */
intel_opregion_setup(display);
/* * Fill the dram structure to get the system dram info. This will be * used for memory latency calculation.
*/
err = intel_dram_detect(xe); if (err) goto err_opregion;
intel_bw_init_hw(display);
intel_display_device_info_runtime_init(display);
err = intel_display_driver_probe_noirq(display); if (err) goto err_opregion;
err = intel_display_driver_probe_nogem(display); if (err) goto err_noirq;
/* * We do a lot of poking in a lot of registers, make sure they work * properly.
*/
intel_power_domains_disable(display);
drm_client_dev_suspend(&xe->drm, false);
if (has_display(xe)) {
drm_kms_helper_poll_disable(&xe->drm);
intel_display_driver_disable_user_access(display);
intel_display_driver_suspend(display);
}
xe_display_flush_cleanup_work(xe);
intel_hpd_cancel_work(display);
if (has_display(xe)) {
intel_display_driver_suspend_access(display);
intel_encoder_suspend_all(display);
}
if (xe->d3cold.allowed)
xe_display_pm_suspend_late(xe);
/* * If xe_display_pm_suspend_late() is not called, it is likely * that we will be on dynamic DC states with DMC wakelock enabled. We * need to flush the release work in that case.
*/
intel_dmc_wl_flush_release_work(display);
}
/* * The only requirement is to reboot with display DC states disabled, * for now leaving all display power wells in the INIT power domain * enabled.
*/
intel_power_domains_driver_remove(display);
}
/** * xe_display_probe - probe display and create display struct * @xe: XE device instance * * Initialize all fields used by the display part. * * TODO: once everything can be inside a single struct, make the struct opaque * to the rest of xe and return it to be xe->display. * * Returns: 0 on success
*/ int xe_display_probe(struct xe_device *xe)
{ struct pci_dev *pdev = to_pci_dev(xe->drm.dev); struct intel_display *display; int err;
if (!xe->info.probe_display) goto no_display;
display = intel_display_device_probe(pdev); if (IS_ERR(display)) return PTR_ERR(display);
err = drmm_add_action_or_reset(&xe->drm, display_device_remove, display); if (err) return err;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.