diff options
author | Tomer Tayar <ttayar@habana.ai> | 2019-07-01 13:59:45 +0000 |
---|---|---|
committer | Oded Gabbay <oded.gabbay@gmail.com> | 2019-07-01 13:59:45 +0000 |
commit | e8960ca06bb22d0d84edf246b0bf395e8322e127 (patch) | |
tree | 1026bbbd6ccc8241fe58bd3742353c647b459c5c /drivers/misc/habanalabs/habanalabs_ioctl.c | |
parent | 06deb86a748a1667d906af996775603f2bc34d00 (diff) | |
download | lwn-e8960ca06bb22d0d84edf246b0bf395e8322e127.tar.gz lwn-e8960ca06bb22d0d84edf246b0bf395e8322e127.zip |
habanalabs: Add busy engines bitmask to HW idle IOCTL
The information which is currently provided as a response to the
"HL_INFO_HW_IDLE" IOCTL is merely a general boolean value.
This patch extends it and provides also a bitmask that indicates which
of the device engines are busy.
Signed-off-by: Tomer Tayar <ttayar@habana.ai>
Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com>
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
Diffstat (limited to 'drivers/misc/habanalabs/habanalabs_ioctl.c')
-rw-r--r-- | drivers/misc/habanalabs/habanalabs_ioctl.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/misc/habanalabs/habanalabs_ioctl.c b/drivers/misc/habanalabs/habanalabs_ioctl.c index b04585af27ad..07127576b3e8 100644 --- a/drivers/misc/habanalabs/habanalabs_ioctl.c +++ b/drivers/misc/habanalabs/habanalabs_ioctl.c @@ -119,7 +119,8 @@ static int hw_idle(struct hl_device *hdev, struct hl_info_args *args) if ((!max_size) || (!out)) return -EINVAL; - hw_idle.is_idle = hdev->asic_funcs->is_device_idle(hdev, NULL); + hw_idle.is_idle = hdev->asic_funcs->is_device_idle(hdev, + &hw_idle.busy_engines_mask, NULL); return copy_to_user(out, &hw_idle, min((size_t) max_size, sizeof(hw_idle))) ? -EFAULT : 0; |