s390x: Avoid _llseek.
There's no _llseek on s390x either. Replace the existing test for __x86_64__ with a functional test for __NR_llseek. Signed-off-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
This commit is contained in:
		
							parent
							
								
									eba0b89379
								
							
						
					
					
						commit
						d35b261c7a
					
				@ -208,7 +208,7 @@ _syscall3(int, sys_getdents, uint, fd, struct linux_dirent *, dirp, uint, count)
 | 
				
			|||||||
_syscall3(int, sys_getdents64, uint, fd, struct linux_dirent64 *, dirp, uint, count);
 | 
					_syscall3(int, sys_getdents64, uint, fd, struct linux_dirent64 *, dirp, uint, count);
 | 
				
			||||||
#endif
 | 
					#endif
 | 
				
			||||||
_syscall2(int, sys_getpriority, int, which, int, who);
 | 
					_syscall2(int, sys_getpriority, int, which, int, who);
 | 
				
			||||||
#if defined(TARGET_NR__llseek) && !defined (__x86_64__)
 | 
					#if defined(TARGET_NR__llseek) && defined(__NR_llseek)
 | 
				
			||||||
_syscall5(int, _llseek,  uint,  fd, ulong, hi, ulong, lo,
 | 
					_syscall5(int, _llseek,  uint,  fd, ulong, hi, ulong, lo,
 | 
				
			||||||
          loff_t *, res, uint, wh);
 | 
					          loff_t *, res, uint, wh);
 | 
				
			||||||
#endif
 | 
					#endif
 | 
				
			||||||
@ -5933,7 +5933,7 @@ abi_long do_syscall(void *cpu_env, int num, abi_long arg1,
 | 
				
			|||||||
#ifdef TARGET_NR__llseek /* Not on alpha */
 | 
					#ifdef TARGET_NR__llseek /* Not on alpha */
 | 
				
			||||||
    case TARGET_NR__llseek:
 | 
					    case TARGET_NR__llseek:
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
#if defined (__x86_64__)
 | 
					#if !defined(__NR_llseek)
 | 
				
			||||||
            ret = get_errno(lseek(arg1, ((uint64_t )arg2 << 32) | arg3, arg5));
 | 
					            ret = get_errno(lseek(arg1, ((uint64_t )arg2 << 32) | arg3, arg5));
 | 
				
			||||||
            if (put_user_s64(ret, arg4))
 | 
					            if (put_user_s64(ret, arg4))
 | 
				
			||||||
                goto efault;
 | 
					                goto efault;
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user