The following problem i found:
1, utimensat01.c still has not been compiled when check_for_utimensat_support
return success.
2, utimensat01 works on only i386 arch.
Signed-off-by: Shi Weihua <[EMAIL PROTECTED]>
---
diff -urpN ltp-full-20080630.orig/testcases/kernel/include/i386.in
ltp-full-20080630/testcases/kernel/include/i386.in
--- ltp-full-20080630.orig/testcases/kernel/include/i386.in 2008-06-29
04:19:03.000000000 +0800
+++ ltp-full-20080630/testcases/kernel/include/i386.in 2008-07-17
14:08:50.000000000 +0800
@@ -20,6 +20,7 @@ __NR_faccessat (__NR_openat + 12)
__NR_splice 313
__NR_tee 315
__NR_vmsplice 316
+__NR_utimensat 320
__NR_timerfd_create 322
__NR_fallocate 324
__NR_timerfd_settime 325
diff -urpN ltp-full-20080630.orig/testcases/kernel/include/ia64.in
ltp-full-20080630/testcases/kernel/include/ia64.in
--- ltp-full-20080630.orig/testcases/kernel/include/ia64.in 2008-07-21
09:44:19.000000000 +0800
+++ ltp-full-20080630/testcases/kernel/include/ia64.in 2008-07-17
14:12:24.000000000 +0800
@@ -16,6 +16,7 @@ __NR_splice 1297
__NR_tee 1301
__NR_vmsplice 1302
__NR_fallocate 1303
+__NR_utimensat 1306
__NR_timerfd_create 1310
__NR_timerfd_settime 1311
__NR_timerfd_gettime 1312
diff -urpN
ltp-full-20080630.orig/testcases/kernel/include/linux_syscall_numbers.h
ltp-full-20080630/testcases/kernel/include/linux_syscall_numbers.h
--- ltp-full-20080630.orig/testcases/kernel/include/linux_syscall_numbers.h
2008-07-21 09:44:19.000000000 +0800
+++ ltp-full-20080630/testcases/kernel/include/linux_syscall_numbers.h
2008-07-17 14:16:12.000000000 +0800
@@ -226,6 +226,9 @@
# ifndef __NR_vmsplice
# define __NR_vmsplice 316
# endif
+# ifndef __NR_utimensat
+# define __NR_utimensat 320
+# endif
# ifndef __NR_timerfd_create
# define __NR_timerfd_create 322
# endif
@@ -296,6 +299,9 @@
# ifndef __NR_fallocate
# define __NR_fallocate 1303
# endif
+# ifndef __NR_utimensat
+# define __NR_utimensat 1306
+# endif
# ifndef __NR_timerfd_create
# define __NR_timerfd_create 1310
# endif
@@ -744,6 +750,9 @@
# ifndef __NR_vmsplice
# define __NR_vmsplice 278
# endif
+# ifndef __NR_utimensat
+# define __NR_utimensat 280
+# endif
# ifndef __NR_timerfd_create
# define __NR_timerfd_create 283
# endif
diff -urpN ltp-full-20080630.orig/testcases/kernel/include/x86_64.in
ltp-full-20080630/testcases/kernel/include/x86_64.in
--- ltp-full-20080630.orig/testcases/kernel/include/x86_64.in 2008-06-29
04:19:03.000000000 +0800
+++ ltp-full-20080630/testcases/kernel/include/x86_64.in 2008-07-17
14:09:09.000000000 +0800
@@ -20,6 +20,7 @@ __NR_faccessat (__NR_openat + 12)
__NR_splice 275
__NR_tee 276
__NR_vmsplice 278
+__NR_utimensat 296
__NR_timerfd_create 283
__NR_fallocate 285
__NR_timerfd_settime 286
diff -urpN
ltp-full-20080630.orig/testcases/kernel/syscalls/utimensat/check_for_utimensat_support.c
ltp-full-20080630/testcases/kernel/syscalls/utimensat/check_for_utimensat_support.c
---
ltp-full-20080630.orig/testcases/kernel/syscalls/utimensat/check_for_utimensat_support.c
2008-06-29 04:19:06.000000000 +0800
+++
ltp-full-20080630/testcases/kernel/syscalls/utimensat/check_for_utimensat_support.c
2008-07-19 17:39:31.000000000 +0800
@@ -8,5 +8,5 @@ int kernel_support_available(void) {
}
int main() {
- exit(kernel_support_available());
+ exit(kernel_support_available());
}
diff -urpN ltp-full-20080630.orig/testcases/kernel/syscalls/utimensat/Makefile
ltp-full-20080630/testcases/kernel/syscalls/utimensat/Makefile
--- ltp-full-20080630.orig/testcases/kernel/syscalls/utimensat/Makefile
2008-06-29 04:19:06.000000000 +0800
+++ ltp-full-20080630/testcases/kernel/syscalls/utimensat/Makefile
2008-07-19 18:14:53.000000000 +0800
@@ -22,12 +22,11 @@ LDLIBS += -L../../../../lib -lltp
SRCS = $(wildcard *.c)
TARGETS = $(patsubst %.c,%,$(SRCS))
-all:
+all:
@set -e; $(MAKE) check_for_utimensat_support; \
- if '. ./check_for_utimensat_support' > /dev/null 2>&1; then \
- $(TARGETS) \
+ if './check_for_utimensat_support' > /dev/null 2>&1; then \
+ $(MAKE) utimensat01; \
else echo "System does not support utimensat syscall support"; true; fi
-
check_for_utimensat_support: check_for_utimensat_support.c
$(CC) -o $@ $< ../../../../lib/tst_kvercmp.c -I../../../../include
@@ -36,8 +35,8 @@ install:
@set -e; \
chmod 755 utimensat_tests.sh; \
ln -f utimensat_tests.sh ../../../bin/utimensat_tests.sh; \
- if '. ./check_for_utimensat_support' > /dev/null 2>&1; then \
- $(TARGETS) install \
+ if './check_for_utimensat_support' > /dev/null 2>&1; then \
+ for i in $(TARGETS); do ln -f $$i ../../../bin/$$i ; done \
else echo "System does not support utimensat syscall support"; true; fi
clean:
diff -urpN
ltp-full-20080630.orig/testcases/kernel/syscalls/utimensat/utimensat01.c
ltp-full-20080630/testcases/kernel/syscalls/utimensat/utimensat01.c
--- ltp-full-20080630.orig/testcases/kernel/syscalls/utimensat/utimensat01.c
2008-06-29 04:19:06.000000000 +0800
+++ ltp-full-20080630/testcases/kernel/syscalls/utimensat/utimensat01.c
2008-07-17 14:05:33.000000000 +0800
@@ -41,6 +41,7 @@
#include <fcntl.h>
#include <string.h>
#include <sys/stat.h>
+#include "linux_syscall_numbers.h"
/* We use EXIT_FAILURE for an expected failure from utimensat()
(e.g., EACCES and EPERM), and one of the following for unexpected
@@ -54,9 +55,6 @@
#define errExit(msg) do { perror(msg); exit(EXIT_failed_syscall); \
} while (0)
-
-#define __NR_utimensat 320 /* x86 syscall number */
-
# define UTIME_NOW ((1l << 30) - 1l)
# define UTIME_OMIT ((1l << 30) - 2l)
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list