diff options
author | Matthew Auld <[email protected]> | 2023-07-19 09:38:06 +0100 |
---|---|---|
committer | Rodrigo Vivi <[email protected]> | 2023-12-21 11:37:35 -0500 |
commit | 2d3ab1fa3195d2b0291625fcd0062796aaf15794 (patch) | |
tree | 7e23a257cf607f044298dfd5028d9fa7aa79fff5 | |
parent | 6bfbd0c589bb89581bb89d2776924c3853296cfc (diff) |
drm/xe/guc_pc: add missing mem_access for freq_rpe_show
The mem_access is meant to cover any kind of device level memory access,
mmio included.
Signed-off-by: Matthew Auld <[email protected]>
Cc: Matthew Brost <[email protected]>
Cc: Rodrigo Vivi <[email protected]>
Cc: Anshuman Gupta <[email protected]>
Reviewed-by: Anshuman Gupta <[email protected]>
Signed-off-by: Rodrigo Vivi <[email protected]>
-rw-r--r-- | drivers/gpu/drm/xe/xe_guc_pc.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/xe/xe_guc_pc.c b/drivers/gpu/drm/xe/xe_guc_pc.c index 03dfbde29fe5..0927cb669603 100644 --- a/drivers/gpu/drm/xe/xe_guc_pc.c +++ b/drivers/gpu/drm/xe/xe_guc_pc.c @@ -422,8 +422,12 @@ static ssize_t freq_rpe_show(struct device *dev, struct device_attribute *attr, char *buf) { struct xe_guc_pc *pc = dev_to_pc(dev); + struct xe_gt *gt = pc_to_gt(pc); + struct xe_device *xe = gt_to_xe(gt); + xe_device_mem_access_get(xe); pc_update_rp_values(pc); + xe_device_mem_access_put(xe); return sysfs_emit(buf, "%d\n", pc->rpe_freq); } static DEVICE_ATTR_RO(freq_rpe); |