提交 ae0e0bda 编写于 作者: mysterywolf's avatar mysterywolf

[cputime] add sys/errno.h

上级 740a8102
......@@ -10,6 +10,7 @@
#include <rtdevice.h>
#include <rtthread.h>
#include <sys/errno.h>
static const struct rt_clock_cputime_ops *_cputime_ops = RT_NULL;
......@@ -24,7 +25,7 @@ float clock_cpu_getres(void)
if (_cputime_ops)
return _cputime_ops->cputime_getres();
rt_set_errno(-ENOSYS);
rt_set_errno(ENOSYS);
return 0;
}
......@@ -38,7 +39,7 @@ uint32_t clock_cpu_gettime(void)
if (_cputime_ops)
return _cputime_ops->cputime_gettime();
rt_set_errno(-ENOSYS);
rt_set_errno(ENOSYS);
return 0;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册