Compat utimensat() returns EINVAL when the tv_nsec is one of UTIME_OMIT or UTIME_NOW and the tv_sec is set to non-zero. As per man pages, the tv_sec field should be ignored. The sys_utimensat() works fine in this case. Signed-off-by: Suzuki K P Index: linux-2.6.31-rc7/fs/compat.c =================================================================== --- linux-2.6.31-rc7.orig/fs/compat.c 2009-08-22 06:30:46.000000000 +0530 +++ linux-2.6.31-rc7/fs/compat.c 2009-08-28 14:14:32.781364904 +0530 @@ -100,13 +100,6 @@ get_compat_timespec(&tv[1], &t[1])) return -EFAULT; - if ((tv[0].tv_nsec == UTIME_OMIT || tv[0].tv_nsec == UTIME_NOW) - && tv[0].tv_sec != 0) - return -EINVAL; - if ((tv[1].tv_nsec == UTIME_OMIT || tv[1].tv_nsec == UTIME_NOW) - && tv[1].tv_sec != 0) - return -EINVAL; - if (tv[0].tv_nsec == UTIME_OMIT && tv[1].tv_nsec == UTIME_OMIT) return 0; }