Lines Matching refs:prog_fd
64 int ret, prog_fd; in test_stream_errors() local
75 prog_fd = bpf_program__fd(*prog); in test_stream_errors()
76 ret = bpf_prog_test_run_opts(prog_fd, &opts); in test_stream_errors()
83 ret = bpf_prog_stream_read(prog_fd, 2, buf, sizeof(buf), &ropts); in test_stream_errors()
89 ret = bpf_prog_stream_read(prog_fd, BPF_STREAM_STDERR, buf, sizeof(buf), &ropts); in test_stream_errors()
107 int ret, prog_fd; in test_stream_syscall() local
114 prog_fd = bpf_program__fd(skel->progs.stream_syscall); in test_stream_syscall()
115 ret = bpf_prog_test_run_opts(prog_fd, &opts); in test_stream_syscall()
123 ASSERT_LT(bpf_prog_stream_read(prog_fd, 0, buf, sizeof(buf), &ropts), 0, "error"); in test_stream_syscall()
127 ASSERT_LT(bpf_prog_stream_read(prog_fd, BPF_STREAM_STDOUT, NULL, sizeof(buf), NULL), 0, "error"); in test_stream_syscall()
131 ret = bpf_prog_stream_read(prog_fd, BPF_STREAM_STDOUT, buf, 2, NULL); in test_stream_syscall()
133 ret = bpf_prog_stream_read(prog_fd, BPF_STREAM_STDOUT, buf, 2, NULL); in test_stream_syscall()
135 ret = bpf_prog_stream_read(prog_fd, BPF_STREAM_STDOUT, buf, 1, &ropts); in test_stream_syscall()
137 ret = bpf_prog_stream_read(prog_fd, BPF_STREAM_STDERR, buf, 1, &ropts); in test_stream_syscall()