Power request bit fix
Changed so that power_request bit will be set if ETHOSU_POWER_Q_DISABLE
instead of ETHOSU_CLOCK_Q_DISABLE.
Change-Id: I571ab165f8856ed71f6e932be401312d43e9cca8
diff --git a/src/ethosu_driver.c b/src/ethosu_driver.c
index e99376a..201eeff 100644
--- a/src/ethosu_driver.c
+++ b/src/ethosu_driver.c
@@ -650,7 +650,7 @@
clock_request = drv->clock_request == 0 ? ETHOSU_CLOCK_Q_ENABLE : ETHOSU_CLOCK_Q_DISABLE;
// Set power request bit for client
- if (power_request == ETHOSU_CLOCK_Q_DISABLE)
+ if (power_request == ETHOSU_POWER_Q_DISABLE)
{
drv->power_request |= (1 << client);
}
@@ -660,6 +660,7 @@
}
// Get current power request (ENABLE if both PMU and INFERENCE asks for power request, else DISABLE)
power_request = drv->power_request == 0 ? ETHOSU_POWER_Q_ENABLE : ETHOSU_POWER_Q_DISABLE;
+
// Set clock and power
enum ethosu_error_codes ret = ethosu_set_clock_and_power(&drv->dev, clock_request, power_request);