Home
last modified time | relevance | path

Searched refs:fcntl (Results 1 – 25 of 115) sorted by relevance

12345

/linux-6.6.21/tools/testing/selftests/core/ !
Dclose_range_test.c78 EXPECT_EQ(-1, fcntl(open_fds[i], F_GETFL)); in TEST()
81 EXPECT_GT(fcntl(open_fds[i], F_GETFL), -1); in TEST()
94 EXPECT_EQ(-1, fcntl(open_fds[i], F_GETFL)); in TEST()
97 EXPECT_GT(fcntl(open_fds[i], F_GETFL), -1); in TEST()
103 EXPECT_EQ(-1, fcntl(open_fds[i], F_GETFL)); in TEST()
105 EXPECT_GT(fcntl(open_fds[i], F_GETFL), -1); in TEST()
109 EXPECT_EQ(-1, fcntl(open_fds[100], F_GETFL)); in TEST()
144 if (fcntl(open_fds[i], F_GETFL) != -1) in TEST()
148 if (fcntl(open_fds[i], F_GETFL) == -1) in TEST()
165 if (fcntl(open_fds[i], F_GETFL) != -1) in TEST()
[all …]
/linux-6.6.21/arch/um/os-Linux/ !
Dfile.c206 if (flags.cl && fcntl(fd, F_SETFD, 1)) { in os_open_file()
368 CATCH_EINTR(err = fcntl(fd, F_SETFD, FD_CLOEXEC)); in os_set_exec_close()
408 flags = fcntl(fd, F_GETFL); in os_set_fd_async()
413 if (fcntl(fd, F_SETFL, flags) < 0) { in os_set_fd_async()
420 if ((fcntl(fd, F_SETSIG, SIGIO) < 0) || in os_set_fd_async()
421 (fcntl(fd, F_SETOWN, os_getpid()) < 0)) { in os_set_fd_async()
435 flags = fcntl(fd, F_GETFL); in os_clear_fd_async()
440 if (fcntl(fd, F_SETFL, flags) < 0) in os_clear_fd_async()
449 flags = fcntl(fd, F_GETFL); in os_set_fd_block()
458 if (fcntl(fd, F_SETFL, flags) < 0) in os_set_fd_block()
[all …]
Dsigio.c433 flags = fcntl(master, F_GETFL); in async_pty()
437 if ((fcntl(master, F_SETFL, flags | O_NONBLOCK | O_ASYNC) < 0) || in async_pty()
438 (fcntl(master, F_SETOWN, os_getpid()) < 0)) in async_pty()
441 if ((fcntl(slave, F_SETFL, flags | O_NONBLOCK) < 0)) in async_pty()
/linux-6.6.21/Documentation/filesystems/ !
Dlocks.rst34 installations use fcntl() instead of flock(). This is true of Slackware 3.0
37 file with fcntl() at the same time as the GDBM routines tried to lock this
46 is to make flock() and fcntl() locks oblivious to each other. Both can
53 cooperative flock()/fcntl() are those that emulate flock() using
54 fcntl(), with all the problems that implies.
Ddnotify.rst12 on a directory using a fcntl(2) call and the notifications themselves
33 information. However, if the F_SETSIG fcntl(2) call is used to let the
66 disabled, fcntl(fd, F_NOTIFY, ...) will return -EINVAL.
/linux-6.6.21/tools/perf/tests/ !
Dbp_signal_overflow.c108 fcntl(fd, F_SETFL, O_RDWR|O_NONBLOCK|O_ASYNC); in test__bp_signal_overflow()
109 fcntl(fd, F_SETSIG, SIGIO); in test__bp_signal_overflow()
110 fcntl(fd, F_SETOWN, getpid()); in test__bp_signal_overflow()
Dbp_signal.c131 fcntl(fd, F_SETFL, O_RDWR|O_NONBLOCK|O_ASYNC); in __event()
132 fcntl(fd, F_SETSIG, sig); in __event()
133 fcntl(fd, F_SETOWN, getpid()); in __event()
/linux-6.6.21/tools/testing/selftests/memfd/ !
Dfuse_test.c68 r = fcntl(fd, F_GET_SEALS); in mfd_assert_get_seals()
95 r = fcntl(fd, F_ADD_SEALS, seals); in mfd_assert_add_seals()
108 r = fcntl(fd, F_GET_SEALS); in mfd_busy_add_seals()
114 r = fcntl(fd, F_ADD_SEALS, seals); in mfd_busy_add_seals()
/linux-6.6.21/tools/testing/selftests/filesystems/ !
Ddnotify_test.c27 fcntl(fd, F_SETSIG, SIGRTMIN + 1); in main()
28 fcntl(fd, F_NOTIFY, DN_MODIFY|DN_CREATE|DN_MULTISHOT); in main()
/linux-6.6.21/tools/crypto/ccp/ !
Dtest_dbc.py7 import fcntl
84 fcntl.ioctl(self.d, INVALID1, self.data, True)
93 fcntl.ioctl(self.d, INVALID2, self.data, True)
102 fcntl.ioctl(self.d, INVALID3, self.data, True)
110 fcntl.ioctl(self.d, INVALID4, self.data, True)
118 fcntl.ioctl(self.d, INVALID5, self.data, True)
/linux-6.6.21/samples/timers/ !
Dhpet_example.c251 if ((fcntl(fd, F_SETOWN, getpid()) == 1) || in hpet_fasync()
252 ((value = fcntl(fd, F_GETFL)) == 1) || in hpet_fasync()
253 (fcntl(fd, F_SETFL, value | O_ASYNC) == 1)) { in hpet_fasync()
/linux-6.6.21/drivers/net/ethernet/sfc/siena/ !
Dmcdi_port_common.c284 u32 speed, u32 flags, u32 fcntl) in efx_mcdi_phy_decode_link() argument
286 switch (fcntl) { in efx_mcdi_phy_decode_link()
1104 u32 fcntl; in efx_siena_mcdi_set_mac() local
1126 fcntl = MC_CMD_FCNTL_BIDIR; in efx_siena_mcdi_set_mac()
1129 fcntl = MC_CMD_FCNTL_RESPOND; in efx_siena_mcdi_set_mac()
1132 fcntl = MC_CMD_FCNTL_OFF; in efx_siena_mcdi_set_mac()
1136 fcntl = MC_CMD_FCNTL_AUTO; in efx_siena_mcdi_set_mac()
1138 fcntl = MC_CMD_FCNTL_OFF; in efx_siena_mcdi_set_mac()
1140 MCDI_SET_DWORD(cmdbytes, SET_MAC_IN_FCNTL, fcntl); in efx_siena_mcdi_set_mac()
1263 u32 flags, fcntl, speed, lpa; in efx_siena_mcdi_process_link_change() local
[all …]
/linux-6.6.21/drivers/net/ethernet/sfc/ !
Dmcdi_port_common.c283 u32 speed, u32 flags, u32 fcntl) in efx_mcdi_phy_decode_link() argument
285 switch (fcntl) { in efx_mcdi_phy_decode_link()
1098 u32 fcntl; in efx_mcdi_set_mac() local
1115 fcntl = MC_CMD_FCNTL_BIDIR; in efx_mcdi_set_mac()
1118 fcntl = MC_CMD_FCNTL_RESPOND; in efx_mcdi_set_mac()
1121 fcntl = MC_CMD_FCNTL_OFF; in efx_mcdi_set_mac()
1125 fcntl = MC_CMD_FCNTL_AUTO; in efx_mcdi_set_mac()
1127 fcntl = MC_CMD_FCNTL_OFF; in efx_mcdi_set_mac()
1129 MCDI_SET_DWORD(cmdbytes, SET_MAC_IN_FCNTL, fcntl); in efx_mcdi_set_mac()
1280 u32 flags, fcntl, speed, lpa; in efx_mcdi_process_link_change() local
[all …]
/linux-6.6.21/tools/testing/selftests/filelock/ !
Dofdlocks.c17 ret = fcntl(fd, F_OFD_SETLK, fl); in lock_set()
29 ret = fcntl(fd, F_OFD_GETLK, fl); in lock_get()
/linux-6.6.21/tools/testing/selftests/tpm2/ !
Dtpm2.py9 import fcntl
369 flags = fcntl.fcntl(self.tpm, fcntl.F_GETFL)
371 fcntl.fcntl(self.tpm, fcntl.F_SETFL, flags)
/linux-6.6.21/Documentation/userspace-api/media/dvb/ !
Dfrontend_f_open.rst20 #include <fcntl.h>
63 versa) using the F_SETFL command of the fcntl system call. This is a
64 standard system call, documented in the Linux manual page for fcntl.
Dca-fopen.rst57 using the ``F_SETFL`` command of the ``fcntl`` system call. This is a
58 standard system call, documented in the Linux manual page for fcntl.
/linux-6.6.21/drivers/staging/media/av7110/ !
Daudio-fopen.rst71 of the fcntl system call. This is a standard system call, documented in
72 the Linux manual page for fcntl. Only one user can open the Audio Device
Dvideo-fopen.rst72 using the F_SETFL command of the fcntl system call. This is a standard
73 system call, documented in the Linux manual page for fcntl. Only one
/linux-6.6.21/tools/testing/selftests/net/af_unix/ !
Dtest_unix_oob.c39 int flags = fcntl(fd, F_GETFL, 0); in set_filemode()
45 fcntl(fd, F_SETFL, flags); in set_filemode()
214 fcntl(pfd, F_SETOWN, getpid()); in main()
/linux-6.6.21/tools/perf/trace/beauty/ !
DBuild2 perf-y += fcntl.o
/linux-6.6.21/tools/testing/selftests/bpf/prog_tests/ !
Dtrace_vprintk.c39 fcntl(fileno(fp), F_SETFL, O_NONBLOCK); in serial_test_trace_vprintk()
Dtrace_printk.c46 fcntl(fileno(fp), F_SETFL, O_NONBLOCK); in serial_test_trace_printk()
/linux-6.6.21/tools/testing/selftests/pidfd/ !
Dpidfd_wait.c196 flags = fcntl(pidfd, F_GETFL, 0); in TEST()
216 ASSERT_EQ(fcntl(pidfd, F_SETFL, (flags & ~O_NONBLOCK)), 0); in TEST()
/linux-6.6.21/arch/loongarch/include/asm/ !
DKbuild11 generic-y += fcntl.h

12345