Revision c6cda17a linux-user/syscall.c

b/linux-user/syscall.c
145 145
#define __NR_sys_getcwd1 __NR_getcwd
146 146
#define __NR_sys_getdents __NR_getdents
147 147
#define __NR_sys_getdents64 __NR_getdents64
148
#define __NR_sys_getpriority __NR_getpriority
148 149
#define __NR_sys_linkat __NR_linkat
149 150
#define __NR_sys_mkdirat __NR_mkdirat
150 151
#define __NR_sys_mknodat __NR_mknodat
......
187 188
#if defined(TARGET_NR_getdents64) && defined(__NR_getdents64)
188 189
_syscall3(int, sys_getdents64, uint, fd, struct dirent64 *, dirp, uint, count);
189 190
#endif
191
_syscall2(int, sys_getpriority, int, which, int, who);
190 192
_syscall5(int, _llseek,  uint,  fd, ulong, hi, ulong, lo,
191 193
          loff_t *, res, uint, wh);
192 194
#if defined(TARGET_NR_linkat) && defined(__NR_linkat)
......
3607 3609
        break;
3608 3610
#endif
3609 3611
    case TARGET_NR_getpriority:
3610
        ret = get_errno(getpriority(arg1, arg2));
3612
        /* libc does special remapping of the return value of
3613
         * sys_getpriority() so it's just easiest to call
3614
         * sys_getpriority() directly rather than through libc. */
3615
        ret = sys_getpriority(arg1, arg2);
3611 3616
        break;
3612 3617
    case TARGET_NR_setpriority:
3613 3618
        ret = get_errno(setpriority(arg1, arg2, arg3));

Also available in: Unified diff