/linux/drivers/gpu/drm/xe/ |
H A D | xe_pm.c | 87 * @xe: The xe device. 92 bool xe_rpm_reclaim_safe(const struct xe_device *xe) in xe_rpm_reclaim_safe() argument 94 return !xe->d3cold.capable; in xe_rpm_reclaim_safe() 97 static void xe_rpm_lockmap_acquire(const struct xe_device *xe) in xe_rpm_lockmap_acquire() argument 99 lock_map_acquire(xe_rpm_reclaim_safe(xe) ? in xe_rpm_lockmap_acquire() 104 static void xe_rpm_lockmap_release(const struct xe_device *xe) in xe_rpm_lockmap_release() argument 106 lock_map_release(xe_rpm_reclaim_safe(xe) ? in xe_rpm_lockmap_release() 113 * @xe: xe devic 117 xe_pm_suspend(struct xe_device * xe) xe_pm_suspend() argument 169 xe_pm_resume(struct xe_device * xe) xe_pm_resume() argument 218 xe_pm_pci_d3cold_capable(struct xe_device * xe) xe_pm_pci_d3cold_capable() argument 242 xe_pm_runtime_init(struct xe_device * xe) xe_pm_runtime_init() argument 265 xe_pm_init_early(struct xe_device * xe) xe_pm_init_early() argument 284 vram_threshold_value(struct xe_device * xe) vram_threshold_value() argument 296 struct xe_device *xe = container_of(nb, struct xe_device, pm_notifier); xe_pm_notifier_callback() local 337 xe_pm_init(struct xe_device * xe) xe_pm_init() argument 366 xe_pm_runtime_fini(struct xe_device * xe) xe_pm_runtime_fini() argument 378 xe_pm_fini(struct xe_device * xe) xe_pm_fini() argument 386 xe_pm_write_callback_task(struct xe_device * xe,struct task_struct * task) xe_pm_write_callback_task() argument 400 xe_pm_read_callback_task(struct xe_device * xe) xe_pm_read_callback_task() argument 418 xe_pm_runtime_suspended(struct xe_device * xe) xe_pm_runtime_suspended() argument 429 xe_pm_runtime_suspend(struct xe_device * xe) xe_pm_runtime_suspend() argument 516 xe_pm_runtime_resume(struct xe_device * xe) xe_pm_runtime_resume() argument 581 xe_rpm_might_enter_cb(const struct xe_device * xe) xe_rpm_might_enter_cb() argument 613 xe_pm_runtime_get(struct xe_device * xe) xe_pm_runtime_get() argument 629 xe_pm_runtime_put(struct xe_device * xe) xe_pm_runtime_put() argument 647 xe_pm_runtime_get_ioctl(struct xe_device * xe) xe_pm_runtime_get_ioctl() argument 664 xe_pm_runtime_get_if_active(struct xe_device * xe) xe_pm_runtime_get_if_active() argument 676 xe_pm_runtime_get_if_in_use(struct xe_device * xe) xe_pm_runtime_get_if_in_use() argument 691 xe_pm_suspending_or_resuming(struct xe_device * xe) xe_pm_suspending_or_resuming() argument 714 xe_pm_runtime_get_noresume(struct xe_device * xe) xe_pm_runtime_get_noresume() argument 733 xe_pm_runtime_resume_and_get(struct xe_device * xe) xe_pm_runtime_resume_and_get() argument 749 xe_pm_assert_unbounded_bridge(struct xe_device * xe) xe_pm_assert_unbounded_bridge() argument 772 xe_pm_set_vram_threshold(struct xe_device * xe,u32 threshold) xe_pm_set_vram_threshold() argument 803 xe_pm_d3cold_allowed_toggle(struct xe_device * xe) xe_pm_d3cold_allowed_toggle() argument [all...] |
H A D | xe_device.c | 76 struct xe_device *xe = to_xe_device(dev); in xe_file_open() local 94 xef->xe = xe; in xe_file_open() 130 * xe_file_get() - Take a reference to the xe file object 131 * @xef: Pointer to the xe file 133 * Anyone with a pointer to xef must take a reference to the xe file 136 * Return: xe file pointer 145 * xe_file_put() - Drop a reference to the xe file object 146 * @xef: Pointer to the xe file 157 struct xe_device *xe in xe_file_close() local 208 struct xe_device *xe = to_xe_device(file_priv->minor->dev); xe_drm_ioctl() local 226 struct xe_device *xe = to_xe_device(file_priv->minor->dev); xe_drm_compat_ioctl() local 310 struct xe_device *xe = to_xe_device(dev); xe_pci_barrier_mmap() local 395 struct xe_device *xe = to_xe_device(dev); xe_device_destroy() local 417 struct xe_device *xe; xe_device_create() local 504 xe_driver_flr_disabled(struct xe_device * xe) xe_driver_flr_disabled() argument 530 __xe_driver_flr(struct xe_device * xe) __xe_driver_flr() argument 576 xe_driver_flr(struct xe_device * xe) xe_driver_flr() argument 586 struct xe_device *xe = arg; xe_driver_flr_fini() local 594 struct xe_device *xe = arg; xe_device_sanitize() local 602 xe_set_dma_info(struct xe_device * xe) xe_set_dma_info() argument 624 verify_lmem_ready(struct xe_device * xe) verify_lmem_ready() argument 631 wait_for_lmem_ready(struct xe_device * xe) wait_for_lmem_ready() argument 679 sriov_update_device_info(struct xe_device * xe) sriov_update_device_info() argument 701 xe_device_probe_early(struct xe_device * xe) xe_device_probe_early() argument 742 probe_has_flat_ccs(struct xe_device * xe) probe_has_flat_ccs() argument 770 xe_device_probe(struct xe_device * xe) xe_device_probe() argument 932 xe_device_remove(struct xe_device * xe) xe_device_remove() argument 943 xe_device_shutdown(struct xe_device * xe) xe_device_shutdown() argument 974 xe_device_wmb(struct xe_device * xe) xe_device_wmb() argument 984 tdf_request_sync(struct xe_device * xe) tdf_request_sync() argument 1015 xe_device_l2_flush(struct xe_device * xe) xe_device_l2_flush() argument 1058 xe_device_td_flush(struct xe_device * xe) xe_device_td_flush() argument 1076 xe_device_ccs_bytes(struct xe_device * xe,u64 size) xe_device_ccs_bytes() argument 1093 xe_device_assert_mem_access(struct xe_device * xe) xe_device_assert_mem_access() argument 1098 xe_device_snapshot_print(struct xe_device * xe,struct drm_printer * p) xe_device_snapshot_print() argument 1119 xe_device_canonicalize_addr(struct xe_device * xe,u64 address) xe_device_canonicalize_addr() argument 1124 xe_device_uncanonicalize_addr(struct xe_device * xe,u64 address) xe_device_uncanonicalize_addr() argument 1131 struct xe_device *xe = arg; xe_device_wedged_fini() local 1151 xe_device_declare_wedged(struct xe_device * xe) xe_device_declare_wedged() argument [all...] |
H A D | xe_bo_evict.c | 15 static int xe_bo_apply_to_pinned(struct xe_device *xe, in xe_bo_apply_to_pinned() argument 24 spin_lock(&xe->pinned.lock); in xe_bo_apply_to_pinned() 32 spin_unlock(&xe->pinned.lock); in xe_bo_apply_to_pinned() 36 spin_lock(&xe->pinned.lock); in xe_bo_apply_to_pinned() 44 spin_unlock(&xe->pinned.lock); in xe_bo_apply_to_pinned() 47 spin_lock(&xe->pinned.lock); in xe_bo_apply_to_pinned() 50 spin_unlock(&xe->pinned.lock); in xe_bo_apply_to_pinned() 58 * @xe: xe device 64 int xe_bo_notifier_prepare_all_pinned(struct xe_device *xe) in xe_bo_notifier_prepare_all_pinned() argument 87 xe_bo_notifier_unprepare_all_pinned(struct xe_device * xe) xe_bo_notifier_unprepare_all_pinned() argument 106 xe_bo_evict_all_user(struct xe_device * xe) xe_bo_evict_all_user() argument 151 xe_bo_evict_all(struct xe_device * xe) xe_bo_evict_all() argument 185 struct xe_device *xe = xe_bo_device(bo); xe_bo_restore_and_map_ggtt() local 225 xe_bo_restore_early(struct xe_device * xe) xe_bo_restore_early() argument 242 xe_bo_restore_late(struct xe_device * xe) xe_bo_restore_late() argument 272 xe_bo_pci_dev_remove_pinned(struct xe_device * xe) xe_bo_pci_dev_remove_pinned() argument 297 xe_bo_pci_dev_remove_all(struct xe_device * xe) xe_bo_pci_dev_remove_all() argument 321 struct xe_device *xe = arg; xe_bo_pinned_fini() local 341 xe_bo_pinned_init(struct xe_device * xe) xe_bo_pinned_init() argument [all...] |
H A D | xe_irq.c | 36 static int xe_irq_msix_init(struct xe_device *xe); 37 static void xe_irq_msix_free(struct xe_device *xe); 38 static int xe_irq_msix_request_irqs(struct xe_device *xe); 39 static void xe_irq_msix_synchronize_irq(struct xe_device *xe); 48 drm_WARN(&mmio->tile->xe->drm, 1, in assert_iir_is_zero() 96 static u32 xelp_intr_disable(struct xe_device *xe) in xelp_intr_disable() argument 98 struct xe_mmio *mmio = xe_root_tile_mmio(xe); in xelp_intr_disable() 112 gu_misc_irq_ack(struct xe_device *xe, const u32 master_ctl) in gu_misc_irq_ack() argument 114 struct xe_mmio *mmio = xe_root_tile_mmio(xe); in gu_misc_irq_ack() 127 static inline void xelp_intr_enable(struct xe_device *xe, boo argument 139 struct xe_device *xe = gt_to_xe(gt); xe_irq_enable_hwe() local 227 gt_engine_identity(struct xe_device * xe,struct xe_mmio * mmio,const unsigned int bank,const unsigned int bit) gt_engine_identity() argument 283 struct xe_device *xe = tile_to_xe(tile); pick_engine_gt() local 311 struct xe_device *xe = tile_to_xe(tile); gt_irq_handler() local 369 struct xe_device *xe = arg; xelp_irq_handler() local 397 dg1_intr_disable(struct xe_device * xe) dg1_intr_disable() argument 415 dg1_intr_enable(struct xe_device * xe,bool stall) dg1_intr_enable() argument 431 struct xe_device *xe = arg; dg1_irq_handler() local 574 vf_irq_reset(struct xe_device * xe) vf_irq_reset() argument 594 xe_irq_reset(struct xe_device * xe) xe_irq_reset() argument 629 vf_irq_postinstall(struct xe_device * xe) vf_irq_postinstall() argument 644 xe_irq_postinstall(struct xe_device * xe) xe_irq_postinstall() argument 675 struct xe_device *xe = arg; vf_mem_irq_handler() local 688 xe_irq_handler(struct xe_device * xe) xe_irq_handler() argument 699 xe_irq_msi_request_irqs(struct xe_device * xe) xe_irq_msi_request_irqs() argument 721 xe_irq_msi_free(struct xe_device * xe) xe_irq_msi_free() argument 732 struct xe_device *xe = arg; irq_uninstall() local 745 xe_irq_init(struct xe_device * xe) xe_irq_init() argument 752 xe_irq_install(struct xe_device * xe) xe_irq_install() argument 784 xe_irq_msi_synchronize_irq(struct xe_device * xe) xe_irq_msi_synchronize_irq() argument 789 xe_irq_suspend(struct xe_device * xe) xe_irq_suspend() argument 801 xe_irq_resume(struct xe_device * xe) xe_irq_resume() argument 828 xe_irq_msix_init(struct xe_device * xe) xe_irq_msix_init() argument 848 struct xe_device *xe = arg; guc2host_irq_handler() local 865 struct xe_device *xe = arg; xe_irq_msix_default_hwe_handler() local 892 xe_irq_msix_alloc_vector(struct xe_device * xe,void * irq_buf,bool dynamic_msix,u16 * msix) xe_irq_msix_alloc_vector() argument 911 xe_irq_msix_release_vector(struct xe_device * xe,u16 msix) xe_irq_msix_release_vector() argument 916 xe_irq_msix_request_irq_internal(struct xe_device * xe,irq_handler_t handler,void * irq_buf,const char * name,u16 msix) xe_irq_msix_request_irq_internal() argument 933 xe_irq_msix_request_irq(struct xe_device * xe,irq_handler_t handler,void * irq_buf,const char * name,bool dynamic_msix,u16 * msix) xe_irq_msix_request_irq() argument 952 xe_irq_msix_free_irq(struct xe_device * xe,u16 msix) xe_irq_msix_free_irq() argument 972 xe_irq_msix_request_irqs(struct xe_device * xe) xe_irq_msix_request_irqs() argument 994 xe_irq_msix_free(struct xe_device * xe) xe_irq_msix_free() argument 1004 xe_irq_msix_synchronize_irq(struct xe_device * xe) xe_irq_msix_synchronize_irq() argument [all...] |
H A D | xe_pci_sriov.c | 34 static int pf_provision_vfs(struct xe_device *xe, unsigned int num_vfs) in pf_provision_vfs() argument 40 for_each_gt(gt, xe, id) { in pf_provision_vfs() 50 static void pf_unprovision_vfs(struct xe_device *xe, unsigned int num_vfs) in pf_unprovision_vfs() argument 56 for_each_gt(gt, xe, id) in pf_unprovision_vfs() 61 static void pf_reset_vfs(struct xe_device *xe, unsigned int num_vfs) in pf_reset_vfs() argument 67 for_each_gt(gt, xe, id) in pf_reset_vfs() 72 static struct pci_dev *xe_pci_pf_get_vf_dev(struct xe_device *xe, unsigned int vf_id) in xe_pci_pf_get_vf_dev() argument 74 struct pci_dev *pdev = to_pci_dev(xe->drm.dev); in xe_pci_pf_get_vf_dev() 76 xe_assert(xe, IS_SRIOV_PF(xe)); in xe_pci_pf_get_vf_dev() 84 static void pf_link_vfs(struct xe_device *xe, int num_vfs) in pf_link_vfs() argument [all …]
|
H A D | xe_sriov.c | 39 static bool test_is_vf(struct xe_device *xe) in test_is_vf() argument 41 u32 value = xe_mmio_read32(xe_root_tile_mmio(xe), VF_CAP_REG); in test_is_vf() 48 * @xe: the &xe_device to probe mode on 57 void xe_sriov_probe_early(struct xe_device *xe) in xe_sriov_probe_early() argument 59 struct pci_dev *pdev = to_pci_dev(xe->drm.dev); in xe_sriov_probe_early() 61 bool has_sriov = xe->info.has_sriov; in xe_sriov_probe_early() 64 if (test_is_vf(xe)) in xe_sriov_probe_early() 66 else if (xe_sriov_pf_readiness(xe)) in xe_sriov_probe_early() 76 drm_info(&xe->drm, "Support for SR-IOV is not available\n"); in xe_sriov_probe_early() 80 xe_assert(xe, !x in xe_sriov_probe_early() 91 struct xe_device *xe = arg; fini_sriov() local 106 xe_sriov_init(struct xe_device * xe) xe_sriov_init() argument 137 xe_sriov_print_info(struct xe_device * xe,struct drm_printer * p) xe_sriov_print_info() argument [all...] |
H A D | xe_sriov_pf.c | 20 static unsigned int wanted_max_vfs(struct xe_device *xe) in wanted_max_vfs() argument 25 static int pf_reduce_totalvfs(struct xe_device *xe, int limit) in pf_reduce_totalvfs() argument 27 struct device *dev = xe->drm.dev; in pf_reduce_totalvfs() 33 xe_sriov_notice(xe, "Failed to set number of VFs to %d (%pe)\n", in pf_reduce_totalvfs() 38 static bool pf_continue_as_native(struct xe_device *xe, const char *why) in pf_continue_as_native() argument 40 xe_sriov_dbg(xe, "%s, continuing as native\n", why); in pf_continue_as_native() 41 pf_reduce_totalvfs(xe, 0); in pf_continue_as_native() 47 * @xe: the &xe_device to check 54 bool xe_sriov_pf_readiness(struct xe_device *xe) in xe_sriov_pf_readiness() argument 56 struct device *dev = xe in xe_sriov_pf_readiness() 86 xe_sriov_pf_init_early(struct xe_device * xe) xe_sriov_pf_init_early() argument 114 xe_sriov_pf_wait_ready(struct xe_device * xe) xe_sriov_pf_wait_ready() argument 139 xe_sriov_pf_print_vfs_summary(struct xe_device * xe,struct drm_printer * p) xe_sriov_pf_print_vfs_summary() argument 155 struct xe_device *xe = parent->d_inode->i_private; simple_show() local 174 xe_sriov_pf_debugfs_register(struct xe_device * xe,struct dentry * root) xe_sriov_pf_debugfs_register() argument [all...] |
H A D | xe_device.h | 34 static inline struct xe_device *xe_device_const_cast(const struct xe_device *xe) in xe_device_const_cast() argument 36 return (struct xe_device *)xe; in xe_device_const_cast() 46 int xe_device_probe_early(struct xe_device *xe); 47 int xe_device_probe(struct xe_device *xe); 48 void xe_device_remove(struct xe_device *xe); 49 void xe_device_shutdown(struct xe_device *xe); 51 void xe_device_wmb(struct xe_device *xe); 58 static inline struct xe_tile *xe_device_get_root_tile(struct xe_device *xe) in xe_device_get_root_tile() argument 60 return &xe->tiles[0]; in xe_device_get_root_tile() 66 * structures should use the per-platform xe 70 xe_device_get_gt(struct xe_device * xe,u8 gt_id) xe_device_get_gt() argument 112 xe_root_mmio_gt(struct xe_device * xe) xe_root_mmio_gt() argument 117 xe_device_uc_enabled(struct xe_device * xe) xe_device_uc_enabled() argument 145 xe_device_has_flat_ccs(struct xe_device * xe) xe_device_has_flat_ccs() argument 150 xe_device_has_sriov(struct xe_device * xe) xe_device_has_sriov() argument 155 xe_device_has_msix(struct xe_device * xe) xe_device_has_msix() argument 160 xe_device_has_memirq(struct xe_device * xe) xe_device_has_memirq() argument 165 xe_device_uses_memirq(struct xe_device * xe) xe_device_uses_memirq() argument 170 xe_device_has_lmtt(struct xe_device * xe) xe_device_has_lmtt() argument 185 xe_device_wedged(struct xe_device * xe) xe_device_wedged() argument [all...] |
H A D | xe_pat.c | 157 u16 xe_pat_index_get_coh_mode(struct xe_device *xe, u16 pat_index) in xe_pat_index_get_coh_mode() argument 159 WARN_ON(pat_index >= xe->pat.n_entries); in xe_pat_index_get_coh_mode() 160 return xe->pat.table[pat_index].coh_mode; in xe_pat_index_get_coh_mode() 166 struct xe_device *xe = gt_to_xe(gt); in program_pat() local 174 if (xe->pat.pat_ats) in program_pat() 175 xe_mmio_write32(>->mmio, XE_REG(_PAT_ATS), xe->pat.pat_ats->value); in program_pat() 176 if (xe->pat.pat_pta) in program_pat() 177 xe_mmio_write32(>->mmio, XE_REG(_PAT_PTA), xe->pat.pat_pta->value); in program_pat() 183 struct xe_device *xe = gt_to_xe(gt); in program_pat_mcr() local 191 if (xe in program_pat_mcr() 199 struct xe_device *xe = gt_to_xe(gt); xelp_dump() local 227 struct xe_device *xe = gt_to_xe(gt); xehp_dump() local 257 struct xe_device *xe = gt_to_xe(gt); xehpc_dump() local 285 struct xe_device *xe = gt_to_xe(gt); xelpg_dump() local 323 struct xe_device *xe = gt_to_xe(gt); xe2_dump() local 378 xe_pat_init_early(struct xe_device * xe) xe_pat_init_early() argument 454 struct xe_device *xe = gt_to_xe(gt); xe_pat_init() local 467 struct xe_device *xe = gt_to_xe(gt); xe_pat_dump() local [all...] |
H A D | xe_sriov_vf.c | 127 static bool vf_migration_supported(struct xe_device *xe) in vf_migration_supported() argument 140 * @xe: the &xe_device to initialize 142 void xe_sriov_vf_init_early(struct xe_device *xe) in xe_sriov_vf_init_early() argument 144 INIT_WORK(&xe->sriov.vf.migration.worker, migration_worker_func); in xe_sriov_vf_init_early() 146 if (!vf_migration_supported(xe)) in xe_sriov_vf_init_early() 147 xe_sriov_info(xe, "migration not supported by this module version\n"); in xe_sriov_vf_init_early() 157 * @xe: the &xe_device struct instance 160 static int vf_post_migration_notify_resfix_done(struct xe_device *xe, unsigned long gt_flags) in vf_post_migration_notify_resfix_done() argument 166 for_each_gt(gt, xe, id) { in vf_post_migration_notify_resfix_done() 179 drm_dbg(&xe in vf_post_migration_notify_resfix_done() 183 vf_get_next_migrated_gt_id(struct xe_device * xe) vf_get_next_migrated_gt_id() argument 226 vf_post_migration_recovery(struct xe_device * xe) vf_post_migration_recovery() argument 265 struct xe_device *xe = container_of(w, struct xe_device, migration_worker_func() local 278 vf_ready_to_recovery_on_any_gts(struct xe_device * xe) vf_ready_to_recovery_on_any_gts() argument 296 xe_sriov_vf_start_migration_recovery(struct xe_device * xe) xe_sriov_vf_start_migration_recovery() argument [all...] |
H A D | xe_sriov_pf_service.c | 18 * @xe: the &xe_device to initialize 24 void xe_sriov_pf_service_init(struct xe_device *xe) in xe_sriov_pf_service_init() argument 29 xe_assert(xe, IS_SRIOV_PF(xe)); in xe_sriov_pf_service_init() 32 xe->sriov.pf.service.version.base.major = GUC_RELAY_VERSION_BASE_MAJOR; in xe_sriov_pf_service_init() 33 xe->sriov.pf.service.version.base.minor = GUC_RELAY_VERSION_BASE_MINOR; in xe_sriov_pf_service_init() 36 xe->sriov.pf.service.version.latest.major = GUC_RELAY_VERSION_LATEST_MAJOR; in xe_sriov_pf_service_init() 37 xe->sriov.pf.service.version.latest.minor = GUC_RELAY_VERSION_LATEST_MINOR; in xe_sriov_pf_service_init() 41 static int pf_negotiate_version(struct xe_device *xe, in pf_negotiate_version() argument 45 struct xe_sriov_pf_service_version base = xe in pf_negotiate_version() 87 pf_connect(struct xe_device * xe,u32 vfid,u32 major,u32 minor) pf_connect() argument 96 pf_disconnect(struct xe_device * xe,u32 vfid) pf_disconnect() argument 117 xe_sriov_pf_service_is_negotiated(struct xe_device * xe,u32 vfid,u32 major,u32 minor) xe_sriov_pf_service_is_negotiated() argument 140 xe_sriov_pf_service_handshake_vf(struct xe_device * xe,u32 vfid,u32 wanted_major,u32 wanted_minor,u32 * major,u32 * minor) xe_sriov_pf_service_handshake_vf() argument 176 xe_sriov_pf_service_reset_vf(struct xe_device * xe,unsigned int vfid) xe_sriov_pf_service_reset_vf() argument 194 xe_sriov_pf_service_print_versions(struct xe_device * xe,struct drm_printer * p) xe_sriov_pf_service_print_versions() argument [all...] |
H A D | xe_debugfs.c | 42 struct xe_device *xe = node_to_xe(m->private); in info() local 47 xe_pm_runtime_get(xe); in info() 49 drm_printf(&p, "graphics_verx100 %d\n", xe->info.graphics_verx100); in info() 50 drm_printf(&p, "media_verx100 %d\n", xe->info.media_verx100); in info() 52 xe_step_name(xe->info.step.graphics), in info() 53 xe_step_name(xe->info.step.media), in info() 54 xe_step_name(xe->info.step.basedie)); in info() 55 drm_printf(&p, "is_dgfx %s\n", str_yes_no(xe->info.is_dgfx)); in info() 56 drm_printf(&p, "platform %d\n", xe->info.platform); in info() 58 xe in info() 80 struct xe_device *xe = node_to_xe(m->private); sriov_info() local 87 workarounds(struct xe_device * xe,struct drm_printer * p) workarounds() argument 98 struct xe_device *xe = node_to_xe(m->private); workaround_info() local 113 struct xe_device *xe = inode->i_private; forcewake_open() local 145 struct xe_device *xe = inode->i_private; forcewake_release() local 165 struct xe_device *xe = file_inode(f)->i_private; wedged_mode_show() local 177 struct xe_device *xe = file_inode(f)->i_private; wedged_mode_set() local 218 struct xe_device *xe = file_inode(f)->i_private; atomic_svm_timeslice_ms_show() local 231 struct xe_device *xe = file_inode(f)->i_private; atomic_svm_timeslice_ms_set() local 250 xe_debugfs_register(struct xe_device * xe) xe_debugfs_register() argument [all...] |
H A D | xe_rtp.c | 27 static bool has_samedia(const struct xe_device *xe) in has_samedia() argument 29 return xe->info.media_verx100 >= 1300; in has_samedia() 32 static bool rule_matches(const struct xe_device *xe, in rule_matches() argument 52 match = xe->info.platform == r->platform; in rule_matches() 55 match = xe->info.platform == r->platform && in rule_matches() 56 xe->info.subplatform == r->subplatform; in rule_matches() 59 if (drm_WARN_ON(&xe->drm, !gt)) in rule_matches() 62 match = xe->info.graphics_verx100 == r->ver_start && in rule_matches() 63 (!has_samedia(xe) || !xe_gt_is_media_type(gt)); in rule_matches() 66 if (drm_WARN_ON(&xe in rule_matches() 187 rtp_process_one_sr(const struct xe_rtp_entry_sr * entry,struct xe_device * xe,struct xe_gt * gt,struct xe_hw_engine * hwe,struct xe_reg_sr * sr) rtp_process_one_sr() argument 213 rtp_get_context(struct xe_rtp_process_ctx * ctx,struct xe_hw_engine ** hwe,struct xe_gt ** gt,struct xe_device ** xe) rtp_get_context() argument 254 rtp_mark_active(struct xe_device * xe,struct xe_rtp_process_ctx * ctx,unsigned int idx) rtp_mark_active() argument 289 struct xe_device *xe = NULL; xe_rtp_process_to_sr() local 332 struct xe_device *xe; xe_rtp_process() local [all...] |
H A D | xe_pci.c | 424 find_subplatform(const struct xe_device *xe, const struct xe_device_desc *desc) in find_subplatform() argument 431 if (*id == xe->info.devid) in find_subplatform() 442 static void read_gmdid(struct xe_device *xe, enum xe_gmdid_type type, u32 *ver, u32 *revid) in read_gmdid() argument 444 struct xe_mmio *mmio = xe_root_tile_mmio(xe); in read_gmdid() 448 KUNIT_STATIC_STUB_REDIRECT(read_gmdid, xe, type, ver, revid); in read_gmdid() 450 if (IS_SRIOV_VF(xe)) { in read_gmdid() 451 struct xe_gt *gt = xe_root_mmio_gt(xe); in read_gmdid() 510 static void handle_gmdid(struct xe_device *xe, in handle_gmdid() argument 521 read_gmdid(xe, GMDID_GRAPHICS, &ver, graphics_revid); in handle_gmdid() 532 drm_err(&xe in handle_gmdid() 559 xe_info_init_early(struct xe_device * xe,const struct xe_device_desc * desc,const struct xe_subplatform_desc * subplatform_desc) xe_info_init_early() argument 607 xe_info_init(struct xe_device * xe,const struct xe_device_desc * desc) xe_info_init() argument 724 struct xe_device *xe = pdev_to_xe_device(pdev); xe_pci_remove() local 759 struct xe_device *xe; xe_pci_probe() local 877 struct xe_device *xe = pdev_to_xe_device(pdev); d3cold_toggle() local 900 struct xe_device *xe = pdev_to_xe_device(pdev); xe_pci_suspend() local 954 struct xe_device *xe = pdev_to_xe_device(pdev); xe_pci_runtime_suspend() local 979 struct xe_device *xe = pdev_to_xe_device(pdev); xe_pci_runtime_resume() local 1002 struct xe_device *xe = pdev_to_xe_device(pdev); xe_pci_runtime_idle() local [all...] |
H A D | xe_ttm_stolen_mgr.c | 49 * @xe: xe device 55 bool xe_ttm_stolen_cpu_access_needs_ggtt(struct xe_device *xe) in xe_ttm_stolen_cpu_access_needs_ggtt() argument 57 return GRAPHICS_VERx100(xe) < 1270 && !IS_DGFX(xe); in xe_ttm_stolen_cpu_access_needs_ggtt() 60 static u32 get_wopcm_size(struct xe_device *xe) in get_wopcm_size() argument 65 val = xe_mmio_read64_2x32(xe_root_tile_mmio(xe), STOLEN_RESERVED); in get_wopcm_size() 83 static s64 detect_bar2_dgfx(struct xe_device *xe, struct xe_ttm_stolen_mgr *mgr) in detect_bar2_dgfx() argument 85 struct xe_tile *tile = xe_device_get_root_tile(xe); in detect_bar2_dgfx() 86 struct xe_mmio *mmio = xe_root_tile_mmio(xe); in detect_bar2_dgfx() 121 detect_bar2_integrated(struct xe_device * xe,struct xe_ttm_stolen_mgr * mgr) detect_bar2_integrated() argument 196 detect_stolen(struct xe_device * xe,struct xe_ttm_stolen_mgr * mgr) detect_stolen() argument 210 xe_ttm_stolen_mgr_init(struct xe_device * xe) xe_ttm_stolen_mgr_init() argument 262 struct xe_device *xe = xe_bo_device(bo); xe_ttm_stolen_io_offset() local 276 __xe_ttm_stolen_io_mem_reserve_bar2(struct xe_device * xe,struct xe_ttm_stolen_mgr * mgr,struct ttm_resource * mem) __xe_ttm_stolen_io_mem_reserve_bar2() argument 300 __xe_ttm_stolen_io_mem_reserve_stolen(struct xe_device * xe,struct xe_ttm_stolen_mgr * mgr,struct ttm_resource * mem) __xe_ttm_stolen_io_mem_reserve_stolen() argument 327 xe_ttm_stolen_io_mem_reserve(struct xe_device * xe,struct ttm_resource * mem) xe_ttm_stolen_io_mem_reserve() argument 341 xe_ttm_stolen_gpu_offset(struct xe_device * xe) xe_ttm_stolen_gpu_offset() argument [all...] |
H A D | xe_sriov_printk.h | 14 #define xe_sriov_printk_prefix(xe) \ argument 15 ((xe)->sriov.__mode == XE_SRIOV_MODE_PF ? "PF: " : \ 16 (xe)->sriov.__mode == XE_SRIOV_MODE_VF ? "VF: " : "") 18 #define xe_sriov_printk(xe, _level, fmt, ...) \ argument 19 drm_##_level(&(xe)->drm, "%s" fmt, xe_sriov_printk_prefix(xe), ##__VA_ARGS__) 21 #define xe_sriov_err(xe, fmt, ...) \ argument 22 xe_sriov_printk((xe), err, fmt, ##__VA_ARGS__) 24 #define xe_sriov_err_ratelimited(xe, fmt, ...) \ argument 25 xe_sriov_printk((xe), err_ratelimite 27 xe_sriov_warn(xe,fmt,...) global() argument 30 xe_sriov_notice(xe,fmt,...) global() argument 33 xe_sriov_info(xe,fmt,...) global() argument 36 xe_sriov_dbg(xe,fmt,...) global() argument 41 xe_sriov_dbg_verbose(xe,fmt,...) global() argument 43 xe_sriov_dbg_verbose(xe,fmt,...) global() argument [all...] |
H A D | xe_vram.c | 27 _resize_bar(struct xe_device *xe, int resno, resource_size_t size) in _resize_bar() argument 29 struct pci_dev *pdev = to_pci_dev(xe->drm.dev); in _resize_bar() 38 drm_info(&xe->drm, "Failed to resize BAR%d to %dM (%pe). Consider enabling 'Resizable BAR' support in your BIOS\n", in _resize_bar() 43 drm_info(&xe->drm, "BAR%d resized to %dM\n", resno, 1 << bar_size); in _resize_bar() 50 static void resize_vram_bar(struct xe_device *xe) in resize_vram_bar() argument 53 struct pci_dev *pdev = to_pci_dev(xe->drm.dev); in resize_vram_bar() 81 drm_info(&xe->drm, in resize_vram_bar() 99 drm_info(&xe->drm, "Attempting to resize bar from %lluMiB -> %lluMiB\n", in resize_vram_bar() 112 drm_info(&xe->drm, "Can't resize VRAM BAR - platform support is missing. Consider enabling 'Resizable BAR' support in your BIOS\n"); in resize_vram_bar() 119 _resize_bar(xe, LMEM_BA in resize_vram_bar() 139 determine_lmem_bar_size(struct xe_device * xe) determine_lmem_bar_size() argument 166 struct xe_device *xe = gt_to_xe(gt); get_flat_ccs_offset() local 224 struct xe_device *xe = tile_to_xe(tile); tile_vram_size() local 277 struct xe_device *xe = arg; vram_fini() local 298 xe_vram_probe(struct xe_device * xe) xe_vram_probe() argument [all...] |
H A D | xe_sriov.h | 18 void xe_sriov_probe_early(struct xe_device *xe); 19 void xe_sriov_print_info(struct xe_device *xe, struct drm_printer *p); 20 int xe_sriov_init(struct xe_device *xe); 22 static inline enum xe_sriov_mode xe_device_sriov_mode(const struct xe_device *xe) in xe_device_sriov_mode() argument 24 xe_assert(xe, xe->sriov.__mode); in xe_device_sriov_mode() 25 return xe->sriov.__mode; in xe_device_sriov_mode() 28 static inline bool xe_device_is_sriov_pf(const struct xe_device *xe) in xe_device_is_sriov_pf() argument 30 return xe_device_sriov_mode(xe) == XE_SRIOV_MODE_PF; in xe_device_is_sriov_pf() 33 static inline bool xe_device_is_sriov_vf(const struct xe_device *xe) in xe_device_is_sriov_vf() argument 39 IS_SRIOV_PF(xe) global() argument 41 IS_SRIOV_PF(xe) global() argument 43 IS_SRIOV_VF(xe) global() argument 45 IS_SRIOV(xe) global() argument [all...] |
H A D | xe_pm.h | 15 int xe_pm_suspend(struct xe_device *xe); 16 int xe_pm_resume(struct xe_device *xe); 18 int xe_pm_init_early(struct xe_device *xe); 19 int xe_pm_init(struct xe_device *xe); 20 void xe_pm_fini(struct xe_device *xe); 21 bool xe_pm_runtime_suspended(struct xe_device *xe); 22 int xe_pm_runtime_suspend(struct xe_device *xe); 23 int xe_pm_runtime_resume(struct xe_device *xe); 24 void xe_pm_runtime_get(struct xe_device *xe); 25 int xe_pm_runtime_get_ioctl(struct xe_device *xe); [all...] |
H A D | xe_pxp_submit.c | 37 struct xe_device *xe = pxp->xe; in allocate_vcs_execution_resources() local 48 q = xe_exec_queue_create(xe, NULL, BIT(hwe->logical_instance), 1, hwe, in allocate_vcs_execution_resources() 57 bo = xe_bo_create_pin_map(xe, tile, NULL, SZ_4K, ttm_bo_type_kernel, in allocate_vcs_execution_resources() 89 struct xe_device *xe = tile_to_xe(tile); in allocate_gsc_client_resources() local 101 xe_assert(xe, hwe); in allocate_gsc_client_resources() 104 vm = xe_vm_create(xe, XE_VM_FLAG_GSC); in allocate_gsc_client_resources() 110 bo = xe_bo_create_pin_map(xe, tile, vm, PXP_BB_SIZE + inout_size * 2, in allocate_gsc_client_resources() 132 q = xe_exec_queue_create(xe, vm, BIT(hwe->logical_instance), 1, hwe, in allocate_gsc_client_resources() 219 static u32 pxp_emit_wait(struct xe_device *xe, struc argument 228 pxp_emit_session_selection(struct xe_device * xe,struct iosys_map * batch,u32 offset,u32 idx) pxp_emit_session_selection() argument 260 pxp_emit_inline_termination(struct xe_device * xe,struct iosys_map * batch,u32 offset) pxp_emit_inline_termination() argument 270 pxp_emit_session_termination(struct xe_device * xe,struct iosys_map * batch,u32 offset,u32 idx) pxp_emit_session_termination() argument 356 struct xe_device *xe = gt_to_xe(gt); pxp_pkt_submit() local 381 emit_pxp_heci_cmd(struct xe_device * xe,struct iosys_map * batch,u64 addr_in,u32 size_in,u64 addr_out,u32 size_out) emit_pxp_heci_cmd() argument 403 struct xe_device *xe = gsc_res->vm->xe; gsccs_send_message() local 505 struct xe_device *xe = gsc_res->vm->xe; xe_pxp_submit_session_init() local 552 struct xe_device *xe = gsc_res->vm->xe; xe_pxp_submit_session_invalidation() local [all...] |
H A D | xe_device_sysfs.c | 40 struct xe_device *xe = pdev_to_xe_device(pdev); in vram_d3cold_threshold_show() local 43 xe_pm_runtime_get(xe); in vram_d3cold_threshold_show() 44 ret = sysfs_emit(buf, "%d\n", xe->d3cold.vram_threshold); in vram_d3cold_threshold_show() 45 xe_pm_runtime_put(xe); in vram_d3cold_threshold_show() 55 struct xe_device *xe = pdev_to_xe_device(pdev); in vram_d3cold_threshold_store() local 63 drm_dbg(&xe->drm, "vram_d3cold_threshold: %u\n", vram_d3cold_threshold); in vram_d3cold_threshold_store() 65 xe_pm_runtime_get(xe); in vram_d3cold_threshold_store() 66 ret = xe_pm_set_vram_threshold(xe, vram_d3cold_threshold); in vram_d3cold_threshold_store() 67 xe_pm_runtime_put(xe); in vram_d3cold_threshold_store() 77 struct xe_device *xe in lb_fan_control_version_show() local 116 struct xe_device *xe = pdev_to_xe_device(to_pci_dev(dev)); lb_voltage_regulator_version_show() local 154 struct xe_device *xe = pdev_to_xe_device(to_pci_dev(dev)); late_bind_create_files() local 187 struct xe_device *xe = pdev_to_xe_device(to_pci_dev(dev)); late_bind_remove_files() local 250 struct xe_device *xe = pdev_to_xe_device(pdev); auto_link_downgrade_capable_show() local 266 struct xe_device *xe = pdev_to_xe_device(pdev); auto_link_downgrade_status_show() local 289 struct xe_device *xe = arg; xe_device_sysfs_fini() local 300 xe_device_sysfs_init(struct xe_device * xe) xe_device_sysfs_init() argument [all...] |
H A D | xe_heci_gsc.c | 107 static int heci_gsc_irq_setup(struct xe_device *xe) in heci_gsc_irq_setup() argument 109 struct xe_heci_gsc *heci_gsc = &xe->heci_gsc; in heci_gsc_irq_setup() 114 drm_err(&xe->drm, "gsc irq error %d\n", heci_gsc->irq); in heci_gsc_irq_setup() 120 drm_err(&xe->drm, "gsc irq init failed %d\n", ret); in heci_gsc_irq_setup() 125 static int heci_gsc_add_device(struct xe_device *xe, const struct heci_gsc_def *def) in heci_gsc_add_device() argument 127 struct xe_heci_gsc *heci_gsc = &xe->heci_gsc; in heci_gsc_add_device() 128 struct pci_dev *pdev = to_pci_dev(xe->drm.dev); in heci_gsc_add_device() 153 drm_err(&xe->drm, "gsc aux init failed %d\n", ret); in heci_gsc_add_device() 161 drm_err(&xe->drm, "gsc aux add failed %d\n", ret); in heci_gsc_add_device() 170 int xe_heci_gsc_init(struct xe_device *xe) in xe_heci_gsc_init() argument 209 xe_heci_gsc_irq_handler(struct xe_device * xe,u32 iir) xe_heci_gsc_irq_handler() argument 229 xe_heci_csc_irq_handler(struct xe_device * xe,u32 iir) xe_heci_csc_irq_handler() argument [all...] |
/linux/drivers/gpu/drm/xe/display/ |
H A D | xe_display.c | 40 static bool has_display(struct xe_device *xe) in has_display() argument 42 struct intel_display *display = xe->display; in has_display() 52 * Note: This is called before xe or display device creation. 72 * Note: This is called before xe or display device creation. 86 static void unset_display_features(struct xe_device *xe) in unset_display_features() argument 88 xe->drm.driver_features &= ~(DRIVER_MODESET | DRIVER_ATOMIC); in unset_display_features() 93 struct xe_device *xe = arg; in xe_display_fini_early() local 94 struct intel_display *display = xe->display; in xe_display_fini_early() 96 if (!xe->info.probe_display) in xe_display_fini_early() 105 int xe_display_init_early(struct xe_device *xe) in xe_display_init_early() argument 152 struct xe_device *xe = arg; xe_display_fini() local 161 xe_display_init(struct xe_device * xe) xe_display_init() argument 176 xe_display_register(struct xe_device * xe) xe_display_register() argument 187 xe_display_unregister(struct xe_device * xe) xe_display_unregister() argument 200 xe_display_irq_handler(struct xe_device * xe,u32 master_ctl) xe_display_irq_handler() argument 211 xe_display_irq_enable(struct xe_device * xe,u32 gu_misc_iir) xe_display_irq_enable() argument 222 xe_display_irq_reset(struct xe_device * xe) xe_display_irq_reset() argument 232 xe_display_irq_postinstall(struct xe_device * xe,struct xe_gt * gt) xe_display_irq_postinstall() argument 252 xe_display_flush_cleanup_work(struct xe_device * xe) xe_display_flush_cleanup_work() argument 273 xe_display_enable_d3cold(struct xe_device * xe) xe_display_enable_d3cold() argument 296 xe_display_disable_d3cold(struct xe_device * xe) xe_display_disable_d3cold() argument 320 xe_display_pm_suspend(struct xe_device * xe) xe_display_pm_suspend() argument 355 xe_display_pm_shutdown(struct xe_device * xe) xe_display_pm_shutdown() argument 386 xe_display_pm_runtime_suspend(struct xe_device * xe) xe_display_pm_runtime_suspend() argument 401 xe_display_pm_suspend_late(struct xe_device * xe) xe_display_pm_suspend_late() argument 412 xe_display_pm_runtime_suspend_late(struct xe_device * xe) xe_display_pm_runtime_suspend_late() argument 430 xe_display_pm_shutdown_late(struct xe_device * xe) xe_display_pm_shutdown_late() argument 445 xe_display_pm_resume_early(struct xe_device * xe) xe_display_pm_resume_early() argument 455 xe_display_pm_resume(struct xe_device * xe) xe_display_pm_resume() argument 490 xe_display_pm_runtime_resume(struct xe_device * xe) xe_display_pm_runtime_resume() argument 526 xe_display_probe(struct xe_device * xe) xe_display_probe() argument [all...] |
H A D | xe_display.h | 18 int xe_display_probe(struct xe_device *xe); 20 int xe_display_init_early(struct xe_device *xe); 21 int xe_display_init(struct xe_device *xe); 23 void xe_display_register(struct xe_device *xe); 24 void xe_display_unregister(struct xe_device *xe); 26 void xe_display_irq_handler(struct xe_device *xe, u32 master_ctl); 27 void xe_display_irq_enable(struct xe_device *xe, u32 gu_misc_iir); 28 void xe_display_irq_reset(struct xe_device *xe); 29 void xe_display_irq_postinstall(struct xe_device *xe, struct xe_gt *gt); 31 void xe_display_pm_suspend(struct xe_device *xe); 45 xe_display_driver_remove(struct xe_device * xe) xe_display_driver_remove() argument 47 xe_display_probe(struct xe_device * xe) xe_display_probe() argument 49 xe_display_init_early(struct xe_device * xe) xe_display_init_early() argument 50 xe_display_init(struct xe_device * xe) xe_display_init() argument 52 xe_display_register(struct xe_device * xe) xe_display_register() argument 53 xe_display_unregister(struct xe_device * xe) xe_display_unregister() argument 55 xe_display_irq_handler(struct xe_device * xe,u32 master_ctl) xe_display_irq_handler() argument 56 xe_display_irq_enable(struct xe_device * xe,u32 gu_misc_iir) xe_display_irq_enable() argument 57 xe_display_irq_reset(struct xe_device * xe) xe_display_irq_reset() argument 58 xe_display_irq_postinstall(struct xe_device * xe,struct xe_gt * gt) xe_display_irq_postinstall() argument 60 xe_display_pm_suspend(struct xe_device * xe) xe_display_pm_suspend() argument 61 xe_display_pm_shutdown(struct xe_device * xe) xe_display_pm_shutdown() argument 62 xe_display_pm_suspend_late(struct xe_device * xe) xe_display_pm_suspend_late() argument 63 xe_display_pm_shutdown_late(struct xe_device * xe) xe_display_pm_shutdown_late() argument 64 xe_display_pm_resume_early(struct xe_device * xe) xe_display_pm_resume_early() argument 65 xe_display_pm_resume(struct xe_device * xe) xe_display_pm_resume() argument 66 xe_display_pm_runtime_suspend(struct xe_device * xe) xe_display_pm_runtime_suspend() argument 67 xe_display_pm_runtime_suspend_late(struct xe_device * xe) xe_display_pm_runtime_suspend_late() argument 68 xe_display_pm_runtime_resume(struct xe_device * xe) xe_display_pm_runtime_resume() argument [all...] |
/linux/drivers/gpu/drm/xe/tests/ |
H A D | xe_sriov_pf_service_kunit.c | 19 struct xe_device *xe; in pf_service_test_init() local 24 xe = test->priv; in pf_service_test_init() 25 KUNIT_ASSERT_EQ(test, xe_sriov_init(xe), 0); in pf_service_test_init() 27 xe_sriov_pf_service_init(xe); in pf_service_test_init() 33 KUNIT_ASSERT_NE(test, 0, xe->sriov.pf.service.version.base.major); in pf_service_test_init() 34 KUNIT_ASSERT_NE(test, 0, xe->sriov.pf.service.version.latest.major); in pf_service_test_init() 35 KUNIT_ASSERT_LE(test, xe->sriov.pf.service.version.base.major, in pf_service_test_init() 36 xe->sriov.pf.service.version.latest.major); in pf_service_test_init() 37 if (xe->sriov.pf.service.version.base.major == xe in pf_service_test_init() 45 struct xe_device *xe = test->priv; pf_negotiate_any() local 58 struct xe_device *xe = test->priv; pf_negotiate_base_match() local 72 struct xe_device *xe = test->priv; pf_negotiate_base_newer() local 90 struct xe_device *xe = test->priv; pf_negotiate_base_next() local 107 struct xe_device *xe = test->priv; pf_negotiate_base_older() local 122 struct xe_device *xe = test->priv; pf_negotiate_base_prev() local 133 struct xe_device *xe = test->priv; pf_negotiate_latest_match() local 147 struct xe_device *xe = test->priv; pf_negotiate_latest_newer() local 161 struct xe_device *xe = test->priv; pf_negotiate_latest_next() local 174 struct xe_device *xe = test->priv; pf_negotiate_latest_older() local 191 struct xe_device *xe = test->priv; pf_negotiate_latest_prev() local [all...] |