OABI/EABI compatability issue with fstatat64 and mixed ABI
kernels. Patch fixes this, seems to be important on debian arm with
EABI capable kernels.
Will fix #472982
Signed-off-by: Vincent Sanders <vince@simtec.co.uk>
--
Regards Vincent
http://www.kyllikki.org/
--- linux-2.6.24/arch/arm/kernel/calls.S 2008-01-24 22:58:37.000000000 +0000
+++ linux-2.6.24-fstatat64/arch/arm/kernel/calls.S 2008-04-05 20:01:11.000000000 +0100
@@ -336,7 +336,7 @@
CALL(sys_mknodat)
/* 325 */ CALL(sys_fchownat)
CALL(sys_futimesat)
- CALL(sys_fstatat64)
+ CALL(ABI(sys_fstatat64, sys_oabi_fstatat64))
CALL(sys_unlinkat)
CALL(sys_renameat)
/* 330 */ CALL(sys_linkat)
--- linux-2.6.24/arch/arm/kernel/sys_oabi-compat.c 2008-01-24 22:58:37.000000000 +0000
+++ linux-2.6.24-fstatat64/arch/arm/kernel/sys_oabi-compat.c 2008-04-05 21:24:56.000000000 +0100
@@ -169,6 +169,28 @@
return error;
}
+asmlinkage long sys_oabi_fstatat64(int dfd, char __user *filename,
+ struct oldabi_stat64 __user *statbuf, int flag)
+{
+ struct kstat stat;
+ int error = -EINVAL;
+
+ if ((flag & ~AT_SYMLINK_NOFOLLOW) != 0)
+ goto out;
+
+ if (flag & AT_SYMLINK_NOFOLLOW)
+ error = vfs_lstat_fd(dfd, filename, &stat);
+ else
+ error = vfs_stat_fd(dfd, filename, &stat);
+
+ if (!error)
+ error = cp_oldabi_stat64(&stat, statbuf);
+
+out:
+ return error;
+}
+
+
struct oabi_flock64 {
short l_type;
short l_whence;
Attachment:
signature.asc
Description: Digital signature