Home
last modified time | relevance | path

Searched refs:SAFE_OPEN (Results 1 – 25 of 247) sorted by relevance

12345678910

/external/ltp/testcases/kernel/logging/kmsg/
Dkmsg01.c70 f = SAFE_OPEN("/dev/kmsg", O_WRONLY); in inject_msg()
96 f = SAFE_OPEN("/dev/kmsg", O_RDONLY | O_NONBLOCK); in find_msg()
252 fd = SAFE_OPEN("/dev/kmsg", O_RDONLY | O_NONBLOCK); in test_read_nonblock()
268 fd = SAFE_OPEN("/dev/kmsg", O_RDONLY); in test_read_block()
284 fd = SAFE_OPEN("/dev/kmsg", O_RDONLY | O_NONBLOCK); in test_partial_read()
360 fd = SAFE_OPEN("/dev/kmsg", O_RDONLY | O_NONBLOCK); in test_read_returns_first_message()
413 fd = SAFE_OPEN("/dev/kmsg", O_RDONLY | O_NONBLOCK); in test_messages_overwritten()
502 fd = SAFE_OPEN("/dev/kmsg", O_RDONLY | O_NONBLOCK); in test_seek()
503 fd2 = SAFE_OPEN("/dev/kmsg", O_RDONLY | O_NONBLOCK); in test_seek()
538 fd = SAFE_OPEN("/dev/kmsg", O_RDONLY | O_NONBLOCK); in test_seek()
/external/ltp/testcases/kernel/syscalls/symlinkat/
Dsymlinkat01.c171 newdirfd = SAFE_OPEN(cleanup, TEST_DIR2, O_DIRECTORY); in setup_every_copy()
185 fd = SAFE_OPEN(cleanup, desc->referencefn1, O_RDWR); in mysymlinkat_test()
189 fd = SAFE_OPEN(cleanup, desc->referencefn2, O_RDONLY); in mysymlinkat_test()
224 olddirfd = SAFE_OPEN(cleanup, TEST_DIR1, O_DIRECTORY); in setup()
225 deldirfd = SAFE_OPEN(cleanup, TEST_DIR3, O_DIRECTORY); in setup()
227 fd = SAFE_OPEN(cleanup, TEST_DIR1 "/" TEST_FILE1, O_CREAT | O_EXCL, 0600); in setup()
/external/ltp/testcases/kernel/pty/
Dpty01.c82 masterfd = SAFE_OPEN(NULL, MASTERCLONE, O_RDWR); in test1()
116 slavefd = SAFE_OPEN(NULL, slavename, O_RDWR); in test1()
200 masterfd = SAFE_OPEN(NULL, MASTERCLONE, O_RDWR); in test2()
215 slavefd = SAFE_OPEN(NULL, slavename, O_RDWR); in test2()
256 masterfd = SAFE_OPEN(NULL, MASTERCLONE, O_RDWR); in test3()
277 masterfd = SAFE_OPEN(NULL, MASTERCLONE, O_RDWR); in test4()
292 slavefd = SAFE_OPEN(NULL, slavename, O_RDWR); in test4()
Dptem01.c62 masterfd = SAFE_OPEN(NULL, MASTERCLONE, O_RDWR); in test1()
141 masterfd = SAFE_OPEN(NULL, MASTERCLONE, O_RDWR); in test2()
219 masterfd = SAFE_OPEN(NULL, MASTERCLONE, O_RDWR); in test3()
267 masterfd = SAFE_OPEN(NULL, MASTERCLONE, O_RDWR); in test4()
388 masterfd = SAFE_OPEN(NULL, MASTERCLONE, O_RDWR); in test6()
/external/ltp/testcases/kernel/syscalls/splice/
Dsplice01.c50 fd_out = SAFE_OPEN(TESTFILE2, O_RDONLY); in check_file()
71 fd_in = SAFE_OPEN(TESTFILE1, O_RDONLY); in splice_test()
72 fd_out = SAFE_OPEN(TESTFILE2, O_WRONLY | O_CREAT | O_TRUNC, 0666); in splice_test()
104 fd_in = SAFE_OPEN(TESTFILE1, O_WRONLY | O_CREAT | O_TRUNC, 0777); in setup()
Dsplice03.c79 rdfd = SAFE_OPEN(TEST_FILE, O_RDONLY); in setup()
81 wrfd = SAFE_OPEN(TEST_FILE2, O_WRONLY | O_CREAT, 0644); in setup()
83 appendfd = SAFE_OPEN(TEST_FILE3, O_RDWR | O_CREAT | O_APPEND, 0644); in setup()
/external/ltp/testcases/kernel/syscalls/tee/
Dtee01.c53 fd_out = SAFE_OPEN(TESTFILE2, O_RDONLY); in check_file()
75 fd_in = SAFE_OPEN(TESTFILE1, O_RDONLY); in tee_test()
76 fd_out = SAFE_OPEN(TESTFILE2, O_WRONLY | O_CREAT | O_TRUNC, 0777); in tee_test()
116 fd_in = SAFE_OPEN(TESTFILE1, O_WRONLY | O_CREAT | O_TRUNC, 0777); in setup()
/external/ltp/testcases/kernel/syscalls/linkat/
Dlinkat01.c236 newdirfd = SAFE_OPEN(cleanup, TEST_DIR2, O_DIRECTORY); in setup_every_copy()
250 fd = SAFE_OPEN(cleanup, desc->referencefn1, in mylinkat_test()
255 fd = SAFE_OPEN(cleanup, desc->referencefn2, in mylinkat_test()
305 olddirfd = SAFE_OPEN(cleanup, TEST_DIR1, O_DIRECTORY); in setup()
306 deldirfd = SAFE_OPEN(cleanup, TEST_DIR3, O_DIRECTORY); in setup()
308 fd = SAFE_OPEN(cleanup, TEST_DIR1 "/" TEST_FILE1, O_CREAT | O_EXCL, 0600); in setup()
/external/ltp/testcases/kernel/syscalls/flock/
Dflock06.c26 fd1 = SAFE_OPEN("testfile", O_RDWR); in verify_flock()
33 fd2 = SAFE_OPEN("testfile", O_RDWR); in verify_flock()
60 fd = SAFE_OPEN("testfile", O_CREAT | O_TRUNC | O_RDWR, 0666); in setup()
Dflock03.c29 fd2 = SAFE_OPEN("testfile", O_RDWR); in childfunc()
62 fd1 = SAFE_OPEN("testfile", O_RDWR); in verify_flock()
88 fd = SAFE_OPEN("testfile", O_CREAT | O_TRUNC | O_RDWR, 0666); in setup()
Dflock04.c32 fd1 = SAFE_OPEN("testfile", O_RDWR); in child()
52 fd2 = SAFE_OPEN("testfile", O_RDWR); in verify_flock()
82 fd = SAFE_OPEN("testfile", O_CREAT | O_TRUNC | O_RDWR, 0644); in setup()
/external/ltp/testcases/kernel/syscalls/fchmod/
Dfchmod06.c74 fd3 = SAFE_OPEN(MNT_POINT"/file", O_RDONLY); in setup()
75 fd1 = SAFE_OPEN("tfile_1", O_RDWR | O_CREAT, 0666); in setup()
76 fd2 = SAFE_OPEN("tfile_2", O_RDWR | O_CREAT, 0666); in setup()
/external/ltp/testcases/kernel/syscalls/fcntl/
Dfcntl33.c114 fd = SAFE_OPEN("file", O_RDONLY); in do_test()
178 SAFE_OPEN("file", O_RDONLY); in do_child()
181 SAFE_OPEN("file", O_WRONLY); in do_child()
184 SAFE_OPEN("file", O_RDWR); in do_child()
/external/ltp/testcases/kernel/syscalls/fanotify/
Dfanotify02.c63 fd = SAFE_OPEN(fname, O_RDWR | O_CREAT, 0700); in test01()
83 fd = SAFE_OPEN(fname, O_RDONLY); in test01()
116 fd = SAFE_OPEN(fname, O_RDONLY); in test01()
120 fd = SAFE_OPEN(".", O_RDONLY | O_DIRECTORY); in test01()
Dfanotify01.c89 fd = SAFE_OPEN(fname, O_RDONLY); in test_fanotify()
108 fd = SAFE_OPEN(fname, O_RDWR | O_CREAT, 0700); in test_fanotify()
141 fd = SAFE_OPEN(fname, O_RDWR); in test_fanotify()
193 fd = SAFE_OPEN(fname, O_RDWR); in test_fanotify()
203 fd = SAFE_OPEN(fname, O_RDWR); in test_fanotify()
/external/ltp/testcases/kernel/syscalls/msync/
Dmsync04.c43 pagemap_fd = SAFE_OPEN("/proc/self/pagemap", O_RDONLY); in get_dirty_bit()
50 pageflags_fd = SAFE_OPEN("/proc/kpageflags", O_RDONLY); in get_dirty_bit()
62 test_fd = SAFE_OPEN("msync04/testfile", O_CREAT | O_TRUNC | O_RDWR); in test_msync()
/external/ltp/testcases/kernel/containers/userns/
Duserns02.c94 fd = SAFE_OPEN(cleanup, path, O_WRONLY, 0644); in main()
100 fd = SAFE_OPEN(cleanup, path, O_WRONLY, 0644); in main()
107 fd = SAFE_OPEN(cleanup, path, O_WRONLY, 0644); in main()
/external/ltp/testcases/kernel/syscalls/preadv/
Dpreadv02.c107 fd1 = SAFE_OPEN("file1", O_RDWR | O_CREAT, 0644); in setup()
109 fd2 = SAFE_OPEN("file2", O_WRONLY | O_CREAT, 0644); in setup()
110 fd4 = SAFE_OPEN(".", O_RDONLY); in setup()
/external/ltp/testcases/kernel/syscalls/lseek/
Dlseek07.c73 *tc->fd = SAFE_OPEN(tc->fname, O_RDWR); in verify_lseek()
88 fd1 = SAFE_OPEN(TFILE1, O_RDWR | O_CREAT, 0644); in setup()
89 fd2 = SAFE_OPEN(TFILE2, O_RDWR | O_CREAT, 0644); in setup()
Dlseek02.c92 fd = SAFE_OPEN(TFILE, O_RDWR | O_CREAT, 0777); in setup()
94 pfd1 = SAFE_OPEN(TFIFO1, O_RDWR, 0777); in setup()
97 pfd2 = SAFE_OPEN(TFIFO2, O_RDWR, 0777); in setup()
/external/ltp/testcases/kernel/syscalls/read/
Dread02.c108 fd2 = SAFE_OPEN(".", O_DIRECTORY); in setup()
112 fd3 = SAFE_OPEN("test_file", O_RDWR); in setup()
124 fd4 = SAFE_OPEN("test_file", O_RDWR | O_DIRECT); in setup()
/external/ltp/testcases/kernel/syscalls/preadv2/
Dpreadv202.c92 fd1 = SAFE_OPEN("file1", O_RDWR | O_CREAT, 0644); in setup()
94 fd2 = SAFE_OPEN("file2", O_WRONLY | O_CREAT, 0644); in setup()
95 fd4 = SAFE_OPEN(".", O_RDONLY); in setup()
/external/ltp/testcases/kernel/syscalls/readdir/
Dreaddir21.c106 del_dir_fd = SAFE_OPEN(cleanup, TEST_DIR, O_RDONLY | O_DIRECTORY); in setup()
109 file_fd = SAFE_OPEN(cleanup, TEST_FILE, O_RDWR | O_CREAT, 0777); in setup()
112 dir_fd = SAFE_OPEN(cleanup, TEST_DIR4, O_RDONLY | O_DIRECTORY); in setup()
/external/ltp/testcases/kernel/syscalls/renameat2/
Drenameat202.c96 olddirfd = SAFE_OPEN(cleanup, TEST_DIR, O_DIRECTORY); in setup()
97 newdirfd = SAFE_OPEN(cleanup, TEST_DIR2, O_DIRECTORY); in setup()
145 fd = SAFE_OPEN(cleanup, contentfile, O_RDONLY); in renameat2_verify()
/external/ltp/testcases/kernel/syscalls/getdents/
Dgetdents02.c142 fd = SAFE_OPEN(cleanup, ".", O_RDONLY); in test_einval()
161 fd = SAFE_OPEN(cleanup, "test", O_CREAT | O_RDWR); in test_enotdir()
181 fd = SAFE_OPEN(cleanup, TEST_DIR, O_DIRECTORY); in test_enoent()

12345678910