[PATCH] drm/xe/pcode: Use int instead of u32 for mailbox status
Umesh Nerlige Ramappa <[email protected]>
| Newsgroups | org.freedesktop.lists.intel-xe |
|---|---|
| Message-ID | <[email protected]> |
Mailbox status is returned as int, but some callers read it as u32 (likely a typo). Use int instead. Signed-off-by: Umesh Nerlige Ramappa <[email protected]> --- v2: One more place to convert u32 to int (Sashiko) --- drivers/gpu/drm/xe/xe_pcode.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/xe/xe_pcode.c b/drivers/gpu/drm/xe/xe_pcode.c index e1b8062541a9..5f7fc61c9b97 100644 --- a/drivers/gpu/drm/xe/xe_pcode.c +++ b/drivers/gpu/drm/xe/xe_pcode.c @@ -148,7 +148,7 @@ int xe_pcode_read(struct xe_tile *tile, u32 mbox, u32 *val, u32 *val1) static int pcode_try_request(struct xe_tile *tile, u32 mbox, u32 request, u32 reply_mask, u32 reply, - u32 *status, bool atomic, int timeout_us, bool locked) + int *status, bool atomic, int timeout_us, bool locked) { int slept, wait = 10; @@ -196,8 +196,7 @@ static int pcode_try_request(struct xe_tile *tile, u32 mbox, int xe_pcode_request(struct xe_tile *tile, u32 mbox, u32 request, u32 reply_mask, u32 reply, int timeout_base_ms) { - u32 status; - int ret; + int status, ret; xe_tile_assert(tile, timeout_base_ms <= 3); @@ -295,10 +294,10 @@ int xe_pcode_init_min_freq_table(struct xe_tile *tile, u32 min_gt_freq, */ int xe_pcode_ready(struct xe_device *xe, bool locked) { - u32 status, request = DGFX_GET_INIT_STATUS; struct xe_tile *tile = xe_device_get_root_tile(xe); long timeout_us = 3 * 60 * USEC_PER_SEC; /* 3 min */ - int ret; + u32 request = DGFX_GET_INIT_STATUS; + int status, ret; if (xe->info.skip_pcode) return 0; -- 2.51.0