[PATCH] Use __LONG_LONG_PAIR in linux/sync_file_range.c
Jakub Jelinek
jakub@redhat.com
Mon Apr 24 10:11:00 GMT 2006
Hi!
So far I think none of the 32-bit big endian arches support this syscall
(and ppc32 will likely need its own implementation of this, as it requires
long long args to be at padded to even arguments), but certainly it doesn't
hurt to follow what linux/posix_fadvise{,64}.c is already doing.
2006-04-24 Jakub Jelinek <jakub@redhat.com>
* sysdeps/unix/sysv/linux/sync_file_range.c (sync_file_range): Use
__LONG_LONG_PAIR macro.
--- libc/sysdeps/unix/sysv/linux/sync_file_range.c 14 Apr 2006 08:07:56 -0000 1.1
+++ libc/sysdeps/unix/sysv/linux/sync_file_range.c 24 Apr 2006 10:01:53 -0000
@@ -29,9 +29,10 @@
int
sync_file_range (int fd, __off64_t from, __off64_t to, int flags)
{
- return INLINE_SYSCALL (sync_file_range, 6, fd, (off_t) (from >> 32),
- (off_t) (from & 0xffffffff), (off_t) (to >> 32),
- (off_t) (to & 0xffffffff), flags);
+ return INLINE_SYSCALL (sync_file_range, 6, fd,
+ __LONG_LONG_PAIR ((long) (from >> 32), (long) from),
+ __LONG_LONG_PAIR ((long) (to >> 32), (long) to),
+ flags);
}
#else
int
Jakub
More information about the Libc-hacker
mailing list