diff options
author | Matt Roper <matthew.d.roper@intel.com> | 2024-09-10 16:47:31 -0700 |
---|---|---|
committer | Matt Roper <matthew.d.roper@intel.com> | 2024-09-11 15:17:43 -0700 |
commit | a3e7fcef52ea737902f32281e271f03ee0a2afa2 (patch) | |
tree | b5f62b4ce95aea26eaeb94e170fbd1d931bf6225 | |
parent | a7945ef770dbabea7bac270872391907174c17a9 (diff) | |
download | lwn-a3e7fcef52ea737902f32281e271f03ee0a2afa2.tar.gz lwn-a3e7fcef52ea737902f32281e271f03ee0a2afa2.zip |
drm/xe/pcode: Convert register access to use xe_mmio
Stop using GT pointers for register access. Although some of the pcode
mailboxes are related to GTs, pcode itself (and the register interface
to access it) are outside the GT and should be accessed through the
tile's MMIO.
Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com>
Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240910234719.3335472-56-matthew.d.roper@intel.com
-rw-r--r-- | drivers/gpu/drm/xe/xe_pcode.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/xe/xe_pcode.c b/drivers/gpu/drm/xe/xe_pcode.c index 7397d556996a..d95d9835de42 100644 --- a/drivers/gpu/drm/xe/xe_pcode.c +++ b/drivers/gpu/drm/xe/xe_pcode.c @@ -44,7 +44,7 @@ static int pcode_mailbox_status(struct xe_tile *tile) [PCODE_ERROR_MASK] = {-EPROTO, "Unknown"}, }; - err = xe_mmio_read32(tile->primary_gt, PCODE_MAILBOX) & PCODE_ERROR_MASK; + err = xe_mmio_read32(&tile->mmio, PCODE_MAILBOX) & PCODE_ERROR_MASK; if (err) { drm_err(&tile_to_xe(tile)->drm, "PCODE Mailbox failed: %d %s", err, err_decode[err].str ?: "Unknown"); @@ -58,7 +58,7 @@ static int __pcode_mailbox_rw(struct xe_tile *tile, u32 mbox, u32 *data0, u32 *d unsigned int timeout_ms, bool return_data, bool atomic) { - struct xe_gt *mmio = tile->primary_gt; + struct xe_mmio *mmio = &tile->mmio; int err; if (tile_to_xe(tile)->info.skip_pcode) |