habanalabs: add new return code to device fd open
authorOfir Bitton <obitton@habana.ai>
Mon, 28 Feb 2022 14:08:20 +0000 (16:08 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 22 May 2022 18:57:34 +0000 (20:57 +0200)
commit4c3b9f6e3bd0480474666f9e016ff57ea0c5ecaa
treedeb41501e3bac1d60d44810b0f1fcc3487c1d553
parent050a6f349a09d3cefb14f4114bfa047b2c5b2a65
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>
drivers/misc/habanalabs/common/device.c
drivers/misc/habanalabs/common/habanalabs.h
drivers/misc/habanalabs/common/habanalabs_drv.c