aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPer Åstrand <per.astrand@arm.com>2021-09-06 17:25:57 +0200
committerPer Åstrand <per.astrand@arm.com>2021-09-06 21:34:11 +0200
commit5c05a33716cfe840e1944fc832e926de2b3b5123 (patch)
treeb3c2a352fc1582ef7ab51096ffeed65a6b645cc4
parentbdcb622a25eecd4dd86b3403aaa59eadde1ea2dd (diff)
downloadethos-u-linux-driver-stack-5c05a33716cfe840e1944fc832e926de2b3b5123.tar.gz
Correct timescale of sleep for stub
Change-Id: Idc818453362bd3cd4d1c35e1e2d1a9f0ccd7a0a6
-rw-r--r--driver_library/src/ethosu_stub.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/driver_library/src/ethosu_stub.cpp b/driver_library/src/ethosu_stub.cpp
index 9dfc029..510007f 100644
--- a/driver_library/src/ethosu_stub.cpp
+++ b/driver_library/src/ethosu_stub.cpp
@@ -76,8 +76,9 @@ int eioctl(int, unsigned long cmd, void *) {
}
}
-int epoll(struct pollfd *, nfds_t, int timeout) {
- sleep(timeout / 2);
+int epoll(struct pollfd *, nfds_t, int timeout_ms) {
+ int t = 1000 * timeout_ms / 2;
+ usleep(t);
return 1;
}
} // namespace EthosU