Lines Matching refs:xe

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 = pdev_to_xe_device(to_pci_dev(dev)); in lb_fan_control_version_show() local
78 struct xe_tile *root = xe_device_get_root_tile(xe); in lb_fan_control_version_show()
83 xe_pm_runtime_get(xe); in lb_fan_control_version_show()
107 xe_pm_runtime_put(xe); in lb_fan_control_version_show()
116 struct xe_device *xe = pdev_to_xe_device(to_pci_dev(dev)); in lb_voltage_regulator_version_show() local
117 struct xe_tile *root = xe_device_get_root_tile(xe); in lb_voltage_regulator_version_show()
122 xe_pm_runtime_get(xe); in lb_voltage_regulator_version_show()
146 xe_pm_runtime_put(xe); in lb_voltage_regulator_version_show()
154 struct xe_device *xe = pdev_to_xe_device(to_pci_dev(dev)); in late_bind_create_files() local
155 struct xe_tile *root = xe_device_get_root_tile(xe); in late_bind_create_files()
159 xe_pm_runtime_get(xe); in late_bind_create_files()
165 drm_dbg(&xe->drm, "Late binding not supported by firmware\n"); in late_bind_create_files()
180 xe_pm_runtime_put(xe); in late_bind_create_files()
187 struct xe_device *xe = pdev_to_xe_device(to_pci_dev(dev)); in late_bind_remove_files() local
188 struct xe_tile *root = xe_device_get_root_tile(xe); in late_bind_remove_files()
192 xe_pm_runtime_get(xe); in late_bind_remove_files()
205 xe_pm_runtime_put(xe); in late_bind_remove_files()
250 struct xe_device *xe = pdev_to_xe_device(pdev); in auto_link_downgrade_capable_show() local
253 xe_pm_runtime_get(xe); in auto_link_downgrade_capable_show()
254 val = xe_mmio_read32(xe_root_tile_mmio(xe), BMG_PCIE_CAP); in auto_link_downgrade_capable_show()
255 xe_pm_runtime_put(xe); in auto_link_downgrade_capable_show()
266 struct xe_device *xe = pdev_to_xe_device(pdev); in auto_link_downgrade_status_show() local
271 xe_pm_runtime_get(xe); in auto_link_downgrade_status_show()
272 ret = xe_pcode_read(xe_device_get_root_tile(xe), in auto_link_downgrade_status_show()
275 xe_pm_runtime_put(xe); in auto_link_downgrade_status_show()
289 struct xe_device *xe = arg; in xe_device_sysfs_fini() local
291 if (xe->d3cold.capable) in xe_device_sysfs_fini()
292 sysfs_remove_file(&xe->drm.dev->kobj, &dev_attr_vram_d3cold_threshold.attr); in xe_device_sysfs_fini()
294 if (xe->info.platform == XE_BATTLEMAGE) { in xe_device_sysfs_fini()
295 sysfs_remove_files(&xe->drm.dev->kobj, auto_link_downgrade_attrs); in xe_device_sysfs_fini()
296 late_bind_remove_files(xe->drm.dev); in xe_device_sysfs_fini()
300 int xe_device_sysfs_init(struct xe_device *xe) in xe_device_sysfs_init() argument
302 struct device *dev = xe->drm.dev; in xe_device_sysfs_init()
305 if (xe->d3cold.capable) { in xe_device_sysfs_init()
311 if (xe->info.platform == XE_BATTLEMAGE) { in xe_device_sysfs_init()
321 return devm_add_action_or_reset(dev, xe_device_sysfs_fini, xe); in xe_device_sysfs_init()