feat: add NTP; fix networking bugs/regressions
This commit is contained in:
@@ -176,6 +176,7 @@ extern "C" {
|
||||
#define MTK_SYS_FBFLIP 150
|
||||
#define MTK_SYS_GETEXECPATH 151
|
||||
#define MTK_SYS_STAT 152
|
||||
#define MTK_SYS_SETUNIXTIME 153
|
||||
/* @SYSCALLS-END */
|
||||
|
||||
#define MTK_SOCK_TCP 1
|
||||
@@ -596,6 +597,10 @@ static inline void mtk_gettime(mtk_datetime *out) {
|
||||
_mtk_syscall1(MTK_SYS_GETTIME, (long)out);
|
||||
}
|
||||
|
||||
static inline int mtk_set_unix_time(int64_t unix_seconds) {
|
||||
return (int)_mtk_syscall1(MTK_SYS_SETUNIXTIME, (long)unix_seconds);
|
||||
}
|
||||
|
||||
static inline void mtk_settz(int offset_minutes) {
|
||||
_mtk_syscall1(MTK_SYS_SETTZ, (long)offset_minutes);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user