public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/4] habanalabs: ignore device unusable status
@ 2021-05-02 15:51 Oded Gabbay
  2021-05-02 15:51 ` [PATCH 2/4] habanalabs: add missing space after casting Oded Gabbay
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Oded Gabbay @ 2021-05-02 15:51 UTC (permalink / raw)
  To: linux-kernel

Some users might want to implement their own policy of when the device
is unusable so we need to ignore this status in the driver and continue
loading as normal.

Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
---
 drivers/misc/habanalabs/common/firmware_if.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/misc/habanalabs/common/firmware_if.c b/drivers/misc/habanalabs/common/firmware_if.c
index fc10cc06f401..a265753f2a53 100644
--- a/drivers/misc/habanalabs/common/firmware_if.c
+++ b/drivers/misc/habanalabs/common/firmware_if.c
@@ -441,9 +441,9 @@ static int fw_read_errors(struct hl_device *hdev, u32 boot_err0_reg,
 	}
 
 	if (err_val & CPU_BOOT_ERR0_DEVICE_UNUSABLE_FAIL) {
-		dev_err(hdev->dev,
-			"Device boot error - device unusable\n");
-		err_exists = true;
+		/* Ignore this bit, don't prevent driver loading */
+		dev_dbg(hdev->dev, "device unusable status is set\n");
+		err_val &= ~CPU_BOOT_ERR0_DEVICE_UNUSABLE_FAIL;
 	}
 
 	security_val = RREG32(cpu_security_boot_status_reg);
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-05-02 15:51 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-05-02 15:51 [PATCH 1/4] habanalabs: ignore device unusable status Oded Gabbay
2021-05-02 15:51 ` [PATCH 2/4] habanalabs: add missing space after casting Oded Gabbay
2021-05-02 15:51 ` [PATCH 3/4] habanalabs: better error print for pin failure Oded Gabbay
2021-05-02 15:51 ` [PATCH 4/4] habanalabs: set dma mask from fw once fw done iatu config Oded Gabbay

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox