summaryrefslogtreecommitdiffstats
path: root/drivers/misc/habanalabs/hwmon.c
diff options
context:
space:
mode:
authorOded Gabbay2019-02-28 09:46:12 +0100
committerGreg Kroah-Hartman2019-02-28 13:04:59 +0100
commita28ce422a6d926c11d7e72a83ccaa4f9b06077ea (patch)
tree65f08f69e8eec0cf7d5272a87e2e612f975c04ec /drivers/misc/habanalabs/hwmon.c
parenthabanalabs: add MMU DRAM default page mapping (diff)
downloadkernel-qcow2-linux-a28ce422a6d926c11d7e72a83ccaa4f9b06077ea.tar.gz
kernel-qcow2-linux-a28ce422a6d926c11d7e72a83ccaa4f9b06077ea.tar.xz
kernel-qcow2-linux-a28ce422a6d926c11d7e72a83ccaa4f9b06077ea.zip
habanalabs: disable CPU access on timeouts
This patch provides a workaround for a bug in the F/W where the response time for a request from KMD may take more then 100ms. This could cause the queue between KMD and the F/W to get out of sync. The WA is to: 1. Increase the timeout of ALL requests to 1s. 2. In case a request isn't answered in time, mark the state as "cpu_disabled" and prevent sending further requests from KMD to the F/W. This will eventually lead to a heartbeat failure and hard reset of the device. Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/habanalabs/hwmon.c')
-rw-r--r--drivers/misc/habanalabs/hwmon.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/misc/habanalabs/hwmon.c b/drivers/misc/habanalabs/hwmon.c
index 9c359a1dd868..7eec21f9b96e 100644
--- a/drivers/misc/habanalabs/hwmon.c
+++ b/drivers/misc/habanalabs/hwmon.c
@@ -10,7 +10,7 @@
#include <linux/pci.h>
#include <linux/hwmon.h>
-#define SENSORS_PKT_TIMEOUT 100000 /* 100ms */
+#define SENSORS_PKT_TIMEOUT 1000000 /* 1s */
#define HWMON_NR_SENSOR_TYPES (hwmon_pwm + 1)
int hl_build_hwmon_channel_info(struct hl_device *hdev,