summaryrefslogtreecommitdiffstats
path: root/drivers/misc
diff options
context:
space:
mode:
authorOded Gabbay <oded.gabbay@gmail.com>2020-08-12 10:15:27 +0300
committerOded Gabbay <oded.gabbay@gmail.com>2020-09-22 18:49:49 +0300
commitf907af183b8bf35393e3057204000c16d8cb9bbe (patch)
tree9535c9473d724aa9152e450bf1646ea07b345d3b /drivers/misc
parentf5b9c8cf25a562b73c80cd4bb252ccb398259056 (diff)
habanalabs: cast int to u32 before printing it with %u
%u is used for unsigned so we need to cast the int variable to u32 to avoid compiler warning. Reported-by: kernel test robot <lkp@intel.com> Reviewed-by: Tomer Tayar <ttayar@habana.ai> Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
Diffstat (limited to 'drivers/misc')
-rw-r--r--drivers/misc/habanalabs/common/device.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/misc/habanalabs/common/device.c b/drivers/misc/habanalabs/common/device.c
index 24b01cce0a38..dcb7f9ca7a67 100644
--- a/drivers/misc/habanalabs/common/device.c
+++ b/drivers/misc/habanalabs/common/device.c
@@ -286,7 +286,7 @@ static int device_early_init(struct hl_device *hdev)
}
for (i = 0 ; i < hdev->asic_prop.completion_queues_count ; i++) {
- snprintf(workq_name, 32, "hl-free-jobs-%u", i);
+ snprintf(workq_name, 32, "hl-free-jobs-%u", (u32) i);
hdev->cq_wq[i] = create_singlethread_workqueue(workq_name);
if (hdev->cq_wq[i] == NULL) {
dev_err(hdev->dev, "Failed to allocate CQ workqueue\n");