diff options
author | Ofir Bitton <obitton@habana.ai> | 2022-02-28 17:08:20 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2022-05-22 21:57:34 +0300 |
commit | 4c3b9f6e3bd0480474666f9e016ff57ea0c5ecaa (patch) | |
tree | deb41501e3bac1d60d44810b0f1fcc3487c1d553 /drivers/misc/habanalabs/common/habanalabs.h | |
parent | 050a6f349a09d3cefb14f4114bfa047b2c5b2a65 (diff) | |
download | linux-4c3b9f6e3bd0480474666f9e016ff57ea0c5ecaa.tar.xz |
habanalabs: add new return code to device fd open
In order to be more informative during device open, we are adding a
new return code -EAGAIN that indicates device is still going through
resource reclaiming and hence it cannot be used yet.
Signed-off-by: Ofir Bitton <obitton@habana.ai>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/habanalabs/common/habanalabs.h')
-rw-r--r-- | drivers/misc/habanalabs/common/habanalabs.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/misc/habanalabs/common/habanalabs.h b/drivers/misc/habanalabs/common/habanalabs.h index 564797766f42..0079f43bc596 100644 --- a/drivers/misc/habanalabs/common/habanalabs.h +++ b/drivers/misc/habanalabs/common/habanalabs.h @@ -2710,6 +2710,7 @@ struct hl_reset_info { * cases where Linux was not loaded to device CPU * @supports_wait_for_multi_cs: true if wait for multi CS is supported * @is_compute_ctx_active: Whether there is an active compute context executing. + * @compute_ctx_in_release: true if the current compute context is being released. */ struct hl_device { struct pci_dev *pdev; @@ -2828,6 +2829,7 @@ struct hl_device { u8 supports_wait_for_multi_cs; u8 stream_master_qid_arr_size; u8 is_compute_ctx_active; + u8 compute_ctx_in_release; /* Parameters for bring-up */ u64 nic_ports_mask; |