cobalt/kernel: adapt adjtime syscall with upstream kernel
PATCH 2/4 cobalt/kernel: adapt adjtime syscall with upstream kernel
compat_timex related definitions moved from compat code into normal timekeeping code. see 4d5f007e in upstream Linux kernel.
Signed-off-by Fino Meng <[email protected]>
Signed-off-by Mingliang Hu <[email protected]>
--- include/cobalt/kernel/compat.h | 4 ++-- kernel/cobalt/posix/compat.c | 4 ++-- kernel/cobalt/posix/syscall32.c | 2 +- kernel/cobalt/posix/syscall32.h | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-)
include/cobalt/kernel/compat.h +2 -2
@@ -105,9 +105,9 @@ int sys32_put_timeval(struct compat_timeval __user *ctv, const struct timeval *tv);int sys32_get_timex (struct timex *tx, -const struct compat_timex __user *ctx); +const struct old_timex32 __user *ctx); -int sys32_put_timex (struct compat_timex __user *ctx, +int sys32_put_timex (struct old_timex32 __user *ctx,const struct timex *tx); ssize_t sys32_get_fdset(fd_set *fds, const compat_fd_set __user *cfds,
kernel/cobalt/posix/compat.c +2 -2
@@ -81,7 +81,7 @@ int sys32_put_timeval(struct compat_timeval __user *ctv,EXPORT_SYMBOL_GPL (sys32_put_timeval);int sys32_get_timex (struct timex *tx, -const struct compat_timex __user *ctx) +const struct old_timex32 __user *ctx) {memset (tx,0 ,sizeof (*tx));
@@ -112,7 +112,7 @@ int sys32_get_timex(struct timex *tx, }EXPORT_SYMBOL_GPL (sys32_get_timex); -int sys32_put_timex (struct compat_timex __user *ctx, +int sys32_put_timex (struct old_timex32 __user *ctx,const struct timex *tx) { if (!access_wok(ctx, sizeof(*ctx)) ||
kernel/cobalt/posix/syscall32.c +1 -1
@@ -172,7 +172,7 @@ COBALT_SYSCALL32emu(clock_settime, current, }COBALT_SYSCALL32emu (clock_adjtime, current, - (clockid_t clock_id, struct compat_timex __user *u_tx)) + (clockid_t clock_id, struct old_timex32 __user *u_tx)) {struct timex tx;int ret;
kernel/cobalt/posix/syscall32.h +1 -1
@@ -65,7 +65,7 @@ COBALT_SYSCALL32emu_DECL(clock_settime,COBALT_SYSCALL32emu_DECL (clock_adjtime, (clockid_t clock_id, - struct compat_timex __user *u_tx)); + struct old_timex32 __user *u_tx)); COBALT_SYSCALL32emu_DECL(clock_nanosleep, (clockid_t clock_id, int flags,
Signature · 1 line
2.20.1