/linux-master/tools/testing/selftests/powerpc/pmu/event_code_tests/ |
H A D | group_constraint_radix_scope_qual_test.c | 41 FAIL_IF(!event_open_with_group(&event, leader.fd)); 45 FAIL_IF(event_open_with_group(&event, leader.fd));
|
H A D | group_constraint_thresh_ctl_test.c | 45 FAIL_IF(!event_open_with_group(&event, leader.fd)); 53 FAIL_IF(event_open_with_group(&event, leader.fd));
|
H A D | group_constraint_thresh_sel_test.c | 44 FAIL_IF(!event_open_with_group(&event, leader.fd)); 52 FAIL_IF(event_open_with_group(&event, leader.fd));
|
/linux-master/kernel/bpf/preload/iterators/ |
H A D | iterators.lskel-big-endian.h | 27 int fd = skel_link_create(prog_fd, 0, BPF_TRACE_ITER); local 29 if (fd > 0) 30 skel->links.dump_bpf_map_fd = fd; 31 return fd; 38 int fd = skel_link_create(prog_fd, 0, BPF_TRACE_ITER); local 40 if (fd > 0) 41 skel->links.dump_bpf_prog_fd = fd; 42 return fd;
|
H A D | iterators.lskel-little-endian.h | 27 int fd = skel_link_create(prog_fd, 0, BPF_TRACE_ITER); local 29 if (fd > 0) 30 skel->links.dump_bpf_map_fd = fd; 31 return fd; 38 int fd = skel_link_create(prog_fd, 0, BPF_TRACE_ITER); local 40 if (fd > 0) 41 skel->links.dump_bpf_prog_fd = fd; 42 return fd;
|
/linux-master/tools/testing/selftests/powerpc/security/ |
H A D | uaccess_flush.c | 25 int fd, passes = 0, iter, rc = 0; local 70 fd = perf_event_open_counter(PERF_TYPE_HW_CACHE, PERF_L1D_READ_MISS_CONFIG, -1); 71 FAIL_IF(fd < 0); 75 FAIL_IF(perf_event_enable(fd)); 89 FAIL_IF(perf_event_reset(fd)); 93 FAIL_IF(read(fd, &v, sizeof(v)) != sizeof(v)); 132 perf_event_disable(fd); 133 close(fd);
|
/linux-master/tools/testing/selftests/bpf/prog_tests/ |
H A D | vrf_socket_lookup.c | 65 int err, fd; local 71 fd = socket(AF_INET, sotype, 0); 72 if (!ASSERT_GE(fd, 0, "socket")) 75 if (!ASSERT_OK(settimeo(fd, TIMEOUT_MS), "settimeo")) 78 return fd; 80 close(fd); 86 int err, fd = -1; local 88 fd = start_server(AF_INET, sotype, ip, port, TIMEOUT_MS); 89 if (!ASSERT_GE(fd, 0, "start_server")) 93 err = setsockopt(fd, SOL_SOCKE 207 int fd, ret = 0; local [all...] |
H A D | lsm_cgroup.c | 46 int fd; local 48 fd = bpf_prog_get_fd_by_id(p.prog_ids[i]); 49 ASSERT_GE(fd, 0, "prog_get_fd_by_id"); 50 ASSERT_OK(bpf_prog_get_info_by_fd(fd, &info, &info_len), 52 close(fd); 80 int err, fd, prio; local 177 fd = socket(AF_UNIX, SOCK_STREAM, 0); 182 ASSERT_LT(fd, 0, "socket(AF_UNIX)"); 183 close(fd); 187 fd [all...] |
/linux-master/tools/perf/util/ |
H A D | data.c | 26 close(files[nr].fd); 75 file->fd = ret; 143 file->fd = ret; 172 if (fstat(file->fd, &st)) 185 int fd = perf_data__is_read(data) ? local 189 if (!fstat(fd, &st) && S_ISFIFO(st.st_mode)) 201 data->file.fptr = fdopen(fd, mode); 204 data->file.fd = fd; 208 data->file.fd 263 int fd; local 303 int fd; local 318 int fd; local [all...] |
/linux-master/drivers/infiniband/hw/hfi1/ |
H A D | file_ops.c | 41 static int assign_ctxt(struct hfi1_filedata *fd, unsigned long arg, u32 len); 44 static int init_user_ctxt(struct hfi1_filedata *fd, 47 static int get_ctxt_info(struct hfi1_filedata *fd, unsigned long arg, u32 len); 48 static int get_base_info(struct hfi1_filedata *fd, unsigned long arg, u32 len); 49 static int user_exp_rcv_setup(struct hfi1_filedata *fd, unsigned long arg, 51 static int user_exp_rcv_clear(struct hfi1_filedata *fd, unsigned long arg, 53 static int user_exp_rcv_invalid(struct hfi1_filedata *fd, unsigned long arg, 55 static int setup_base_ctxt(struct hfi1_filedata *fd, 59 static int find_sub_ctxt(struct hfi1_filedata *fd, 61 static int allocate_ctxt(struct hfi1_filedata *fd, struc 148 struct hfi1_filedata *fd; local 183 struct hfi1_filedata *fd = fp->private_data; local 261 struct hfi1_filedata *fd = kiocb->ki_filp->private_data; local 320 struct hfi1_filedata *fd = fp->private_data; local 742 complete_subctxt(struct hfi1_filedata *fd) argument 775 assign_ctxt(struct hfi1_filedata *fd, unsigned long arg, u32 len) argument 844 match_ctxt(struct hfi1_filedata *fd, const struct hfi1_user_info *uinfo, struct hfi1_ctxtdata *uctxt) argument 906 find_sub_ctxt(struct hfi1_filedata *fd, const struct hfi1_user_info *uinfo) argument 931 allocate_ctxt(struct hfi1_filedata *fd, struct hfi1_devdata *dd, struct hfi1_user_info *uinfo, struct hfi1_ctxtdata **rcd) argument 1127 get_ctxt_info(struct hfi1_filedata *fd, unsigned long arg, u32 len) argument 1169 init_user_ctxt(struct hfi1_filedata *fd, struct hfi1_ctxtdata *uctxt) argument 1185 setup_base_ctxt(struct hfi1_filedata *fd, struct hfi1_ctxtdata *uctxt) argument 1244 get_base_info(struct hfi1_filedata *fd, unsigned long arg, u32 len) argument 1330 user_exp_rcv_setup(struct hfi1_filedata *fd, unsigned long arg, u32 len) argument 1376 user_exp_rcv_clear(struct hfi1_filedata *fd, unsigned long arg, u32 len) argument 1409 user_exp_rcv_invalid(struct hfi1_filedata *fd, unsigned long arg, u32 len) argument 1440 struct hfi1_filedata *fd = fp->private_data; local 1463 struct hfi1_filedata *fd = fp->private_data; local [all...] |
/linux-master/tools/testing/selftests/net/ |
H A D | tls.c | 110 int *fd, int *cfd, bool *notls) 123 *fd = socket(AF_INET, SOCK_STREAM, 0); 134 ret = connect(*fd, &addr, sizeof(addr)); 142 ret = setsockopt(*fd, IPPROTO_TCP, TCP_ULP, "tls", sizeof("tls")); 155 static int tls_send_cmsg(int fd, unsigned char record_type, argument 179 return sendmsg(fd, &msg, flags); 183 int fd, unsigned char record_type, 201 n = recvmsg(fd, &msg, flags); 215 int fd, cfd; local 221 ulp_sock_pair(_metadata, &self->fd, 109 ulp_sock_pair(struct __test_metadata *_metadata, int *fd, int *cfd, bool *notls) argument 182 tls_recv_cmsg(struct __test_metadata *_metadata, int fd, unsigned char record_type, void *data, size_t len, int flags) argument 271 int fd, cfd; local 442 int fd = mkstemp(filename); local 1186 struct pollfd fd = { 0, 0, 0 }; local 1205 struct pollfd fd = { 0, 0, 0 }; local 1219 struct pollfd fd = { 0, 0, 0 }; local 1359 int i, fd, child_id; local 1654 int fd, cfd; local 1971 int sfd, ret, fd; local 2022 int ret, fd, cfd; local 2047 int ret, fd, cfd, val; local 2099 int sfd, ret, fd; local 2155 int sfd, cfd, ret, fd; local [all...] |
H A D | toeplitz.c | 95 int fd; member in struct:ring_state 257 static char *setup_ring(int fd) argument 272 if (setsockopt(fd, SOL_PACKET, PACKET_RX_RING, &req3, sizeof(req3))) 280 MAP_SHARED | MAP_LOCKED | MAP_POPULATE, fd, 0); 287 static void __set_filter(int fd, int off_proto, uint8_t proto, int off_dport) argument 303 if (setsockopt(fd, SOL_SOCKET, SO_ATTACH_FILTER, &prog, sizeof(prog))) 308 static void set_filter(int fd) argument 315 __set_filter(fd, offsetof(struct iphdr, protocol), proto, 318 __set_filter(fd, offsetof(struct ip6_hdr, ip6_nxt), proto, 323 static void set_filter_null(int fd) argument 344 int fd, val; local 386 int fd, val; local [all...] |
/linux-master/tools/testing/vsock/ |
H A D | util.c | 63 void vsock_wait_remote_close(int fd) argument 75 ev.data.fd = fd; 76 if (epoll_ctl(epollfd, EPOLL_CTL_ADD, fd, &ev) == -1) { 94 assert(ev.data.fd == fd); 155 int fd; local 159 fd = socket(AF_VSOCK, type, 0); 160 if (fd < 0) { 167 ret = connect(fd, 205 int fd; local 237 int fd, client_fd, old_errno; local 297 send_buf(int fd, const void *buf, size_t len, int flags, ssize_t expected_ret) argument 350 recv_buf(int fd, void *buf, size_t len, int flags, ssize_t expected_ret) argument 402 send_byte(int fd, int expected_ret, int flags) argument 416 recv_byte(int fd, int expected_ret, int flags) argument [all...] |
H A D | control.c | 52 int fd; local 55 fd = socket(ai->ai_family, ai->ai_socktype, ai->ai_protocol); 56 if (fd < 0) 60 if (connect(fd, ai->ai_addr, ai->ai_addrlen) < 0) 62 control_fd = fd; 68 if (setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, 74 if (bind(fd, ai->ai_addr, ai->ai_addrlen) < 0) 76 if (listen(fd, 1) < 0) 83 control_fd = accept(fd, NULL, 0); 84 close(fd); [all...] |
/linux-master/arch/um/kernel/ |
H A D | physmem.c | 45 int fd, err; local 47 fd = phys_mapping(phys, &offset); 48 err = os_map_memory((void *) virt, fd, offset, len, r, w, x); 55 "err = %d\n", virt, fd, offset, len, r, w, x, err); 120 int fd = -1; local 123 fd = physmem_fd; 132 fd = region->fd; 140 fd = physmem_fd; 144 return fd; [all...] |
/linux-master/tools/perf/bench/ |
H A D | breakpoint.c | 43 int fd; member in struct:breakpoint 50 int fd; local 60 fd = syscall(SYS_perf_event_open, &attr, 0, -1, -1, 0); 62 if (fd < 0) 63 fd = -errno; 65 return fd; 130 breakpoints[i].fd = breakpoint_setup(&breakpoints[i].watched); 132 if (breakpoints[i].fd < 0) { 133 if (breakpoints[i].fd == -ENODEV) { 150 close(breakpoints[i].fd); 202 int fd; local [all...] |
/linux-master/tools/testing/selftests/cachestat/ |
H A D | test_cachestat.c | 35 bool write_exactly(int fd, size_t filesize) argument 71 /* write random data to fd */ 75 ssize_t write_len = write(fd, cursor, remained); 100 static bool is_on_tmpfs(int fd) argument 104 if (fstatfs(fd, &statfs_buf)) 128 int fd = open(filename, open_flags, open_mode); local 130 if (fd == -1) { 139 if (!write_exactly(fd, filesize)) { 146 syscall_ret = syscall(__NR_cachestat, fd, &cs_range, &cs, 0); 168 if (is_on_tmpfs(fd)) { 215 int fd = shm_open(filename, O_CREAT | O_RDWR, 0600); local [all...] |
/linux-master/arch/um/os-Linux/ |
H A D | umid.c | 139 int fd, p, n, err; local 148 fd = open(file, O_RDONLY); 149 if (fd < 0) { 150 fd = -errno; 151 if (fd != -ENOENT) { 153 "file '%s', err = %d\n", file, -fd); 159 n = read(fd, pid, sizeof(pid)); 184 close(fd); 213 int fd, n; local 223 fd 256 int fd, err; local [all...] |
/linux-master/tools/testing/selftests/exec/ |
H A D | execveat.c | 33 static int execveat_(int fd, const char *path, char **argv, char **envp, argument 37 return syscall(__NR_execveat, fd, path, argv, envp, flags); 44 #define check_execveat_fail(fd, path, flags, errno) \ 45 _check_execveat_fail(fd, path, flags, errno, #errno) 46 static int _check_execveat_fail(int fd, const char *path, int flags, argument 55 fd, path?:"(null)", flags, errno_str); 56 rc = execveat_(fd, path, argv, envp, flags); 74 static int check_execveat_invoked_rc(int fd, const char *path, int flags, argument 86 fd, path, (path + pathlen - 20), flags); 90 fd, pat 130 check_execveat(int fd, const char *path, int flags) argument 146 int fd = open(filename, flags); local 172 int fd; local 253 int fd = open_or_die("execveat", O_RDONLY); local 397 int fd; local [all...] |
/linux-master/tools/spi/ |
H A D | spidev_test.c | 118 static void transfer(int fd, uint8_t const *tx, uint8_t const *rx, size_t len) argument 150 ret = ioctl(fd, SPI_IOC_MESSAGE(1), &tr); 333 static void transfer_escaped_string(int fd, char *str) argument 348 transfer(fd, tx, rx, size); 353 static void transfer_file(int fd, char *filename) argument 380 transfer(fd, tx, rx, sb.st_size); 403 static void transfer_buf(int fd, int len) argument 419 transfer(fd, tx, rx, len); 440 int fd; local 448 fd [all...] |
/linux-master/drivers/clk/ |
H A D | clk-xgene.c | 239 struct xgene_clk_pmd *fd = to_xgene_clk_pmd(hw); local 244 if (fd->lock) 245 spin_lock_irqsave(fd->lock, flags); 247 __acquire(fd->lock); 249 val = readl(fd->reg); 251 if (fd->lock) 252 spin_unlock_irqrestore(fd->lock, flags); 254 __release(fd->lock); 258 scale = (val & fd->mask) >> fd 276 struct xgene_clk_pmd *fd = to_xgene_clk_pmd(hw); local 295 struct xgene_clk_pmd *fd = to_xgene_clk_pmd(hw); local 345 struct xgene_clk_pmd *fd; local [all...] |
/linux-master/fs/hfs/ |
H A D | extent.c | 110 static int __hfs_ext_write_extent(struct inode *inode, struct hfs_find_data *fd) argument 114 hfs_ext_build_key(fd->search_key, inode->i_ino, HFS_I(inode)->cached_start, 116 res = hfs_brec_find(fd); 121 res = hfs_bmap_reserve(fd->tree, fd->tree->depth + 1); 124 hfs_brec_insert(fd, HFS_I(inode)->cached_extents, sizeof(hfs_extent_rec)); 129 hfs_bnode_write(fd->bnode, HFS_I(inode)->cached_extents, fd->entryoffset, fd->entrylength); 137 struct hfs_find_data fd; local 150 __hfs_ext_read_extent(struct hfs_find_data *fd, struct hfs_extent *extent, u32 cnid, u32 block, u8 type) argument 169 __hfs_ext_cache_extent(struct hfs_find_data *fd, struct inode *inode, u32 block) argument 193 struct hfs_find_data fd; local 289 struct hfs_find_data fd; local 479 struct hfs_find_data fd; local [all...] |
/linux-master/tools/testing/selftests/net/mptcp/ |
H A D | mptcp_inq.c | 203 static void wait_for_ack(int fd, int timeout, size_t total) argument 211 ret = ioctl(fd, TIOCOUTQ, &queued); 215 ret = ioctl(fd, SIOCOUTQNSD, &nsd); 235 static void connect_one_server(int fd, int unixfd) argument 262 ret = write(fd, buf, len); 279 wait_for_ack(fd, 5000, len); 287 ret = write(fd, buf, len); 301 wait_for_ack(fd, 5000, sent); 303 ret = write(fd, buf, 1); 305 close(fd); 326 process_one_client(int fd, int unixfd) argument 461 int fd = accept(s, NULL, 0); local 471 int fd = -1, r, on = 1; local 501 int fd = -1; local [all...] |
/linux-master/arch/microblaze/kernel/ |
H A D | sys_microblaze.c | 37 unsigned long, prot, unsigned long, flags, unsigned long, fd, 43 return ksys_mmap_pgoff(addr, len, prot, flags, fd, pgoff >> PAGE_SHIFT); 47 unsigned long, prot, unsigned long, flags, unsigned long, fd, 53 return ksys_mmap_pgoff(addr, len, prot, flags, fd,
|
/linux-master/include/linux/ |
H A D | fd.h | 5 #include <uapi/linux/fd.h>
|