🆕 usleep()、nanosleep()

This commit is contained in:
fslongjin
2022-07-12 12:01:51 +08:00
parent 4208c56074
commit 676260c537
21 changed files with 277 additions and 15 deletions

16
kernel/time/sleep.h Normal file
View File

@ -0,0 +1,16 @@
#pragma once
#include <common/glib.h>
#include <process/ptrace.h>
#include <common/time.h>
/**
* @brief 休眠指定时间
*
* @param rqtp 指定休眠的时间
* @param rmtp 返回的剩余休眠时间
* @return int
*/
int nanosleep(const struct timespec *rqtp, struct timespec *rmtp);