2018-05-02 06:20:06 +03:00
|
|
|
#include <unistd.h>
|
|
|
|
#include <syscall.h>
|
2018-12-10 04:09:27 +03:00
|
|
|
#include <syscall_nums.h>
|
2018-05-02 06:20:06 +03:00
|
|
|
|
2021-05-31 04:47:02 +03:00
|
|
|
DEFN_SYSCALL2(sleep, SYS_SLEEP, unsigned long, unsigned long);
|
2018-05-02 06:20:06 +03:00
|
|
|
|
|
|
|
int usleep(useconds_t usec) {
|
2021-05-31 04:47:02 +03:00
|
|
|
syscall_sleep((usec / 10000) / 1000, (usec / 10000) % 1000);
|
2018-05-02 06:20:06 +03:00
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|