aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm
diff options
context:
space:
mode:
authorOleg Drokin <green@linuxhacker.ru>2009-04-08 12:05:42 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2009-04-20 23:02:51 -0400
commit0112fc2229847feb6c4eb011e6833d8f1742a375 (patch)
treec5bda0b4f5a5f942478faf2fb5961df7fbd15546 /arch/arm
parentfd56d242b3b80b6f2ca174272b20029aae61df75 (diff)
Separate out common fstatat code into vfs_fstatat
This is a version incorporating Christoph's suggestion. Separate out common *fstatat functionality into a single function instead of duplicating it all over the code. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/kernel/sys_oabi-compat.c19
1 files changed, 5 insertions, 14 deletions
diff --git a/arch/arm/kernel/sys_oabi-compat.c b/arch/arm/kernel/sys_oabi-compat.c
index e04173c7e621..d59a0cd537f0 100644
--- a/arch/arm/kernel/sys_oabi-compat.c
+++ b/arch/arm/kernel/sys_oabi-compat.c
@@ -177,21 +177,12 @@ asmlinkage long sys_oabi_fstatat64(int dfd,
177 int flag) 177 int flag)
178{ 178{
179 struct kstat stat; 179 struct kstat stat;
180 int error = -EINVAL; 180 int error;
181 181
182 if ((flag & ~AT_SYMLINK_NOFOLLOW) != 0) 182 error = vfs_fstatat(dfd, filename, &stat, flag);
183 goto out; 183 if (error)
184 184 return error;
185 if (flag & AT_SYMLINK_NOFOLLOW) 185 return cp_oldabi_stat64(&stat, statbuf);
186 error = vfs_lstat_fd(dfd, filename, &stat);
187 else
188 error = vfs_stat_fd(dfd, filename, &stat);
189
190 if (!error)
191 error = cp_oldabi_stat64(&stat, statbuf);
192
193out:
194 return error;
195} 186}
196 187
197struct oabi_flock64 { 188struct oabi_flock64 {