|
@@ -43,8 +43,9 @@ extern u8 hvclock_page
|
|
|
notrace static long vdso_fallback_gettime(long clock, struct timespec *ts)
|
|
|
{
|
|
|
long ret;
|
|
|
- asm("syscall" : "=a" (ret) :
|
|
|
- "0" (__NR_clock_gettime), "D" (clock), "S" (ts) : "memory");
|
|
|
+ asm ("syscall" : "=a" (ret), "=m" (*ts) :
|
|
|
+ "0" (__NR_clock_gettime), "D" (clock), "S" (ts) :
|
|
|
+ "memory", "rcx", "r11");
|
|
|
return ret;
|
|
|
}
|
|
|
|
|
@@ -52,8 +53,9 @@ notrace static long vdso_fallback_gtod(struct timeval *tv, struct timezone *tz)
|
|
|
{
|
|
|
long ret;
|
|
|
|
|
|
- asm("syscall" : "=a" (ret) :
|
|
|
- "0" (__NR_gettimeofday), "D" (tv), "S" (tz) : "memory");
|
|
|
+ asm ("syscall" : "=a" (ret), "=m" (*tv), "=m" (*tz) :
|
|
|
+ "0" (__NR_gettimeofday), "D" (tv), "S" (tz) :
|
|
|
+ "memory", "rcx", "r11");
|
|
|
return ret;
|
|
|
}
|
|
|
|
|
@@ -64,12 +66,12 @@ notrace static long vdso_fallback_gettime(long clock, struct timespec *ts)
|
|
|
{
|
|
|
long ret;
|
|
|
|
|
|
- asm(
|
|
|
+ asm (
|
|
|
"mov %%ebx, %%edx \n"
|
|
|
"mov %2, %%ebx \n"
|
|
|
"call __kernel_vsyscall \n"
|
|
|
"mov %%edx, %%ebx \n"
|
|
|
- : "=a" (ret)
|
|
|
+ : "=a" (ret), "=m" (*ts)
|
|
|
: "0" (__NR_clock_gettime), "g" (clock), "c" (ts)
|
|
|
: "memory", "edx");
|
|
|
return ret;
|
|
@@ -79,12 +81,12 @@ notrace static long vdso_fallback_gtod(struct timeval *tv, struct timezone *tz)
|
|
|
{
|
|
|
long ret;
|
|
|
|
|
|
- asm(
|
|
|
+ asm (
|
|
|
"mov %%ebx, %%edx \n"
|
|
|
"mov %2, %%ebx \n"
|
|
|
"call __kernel_vsyscall \n"
|
|
|
"mov %%edx, %%ebx \n"
|
|
|
- : "=a" (ret)
|
|
|
+ : "=a" (ret), "=m" (*tv), "=m" (*tz)
|
|
|
: "0" (__NR_gettimeofday), "g" (tv), "c" (tz)
|
|
|
: "memory", "edx");
|
|
|
return ret;
|