Lines Matching +full:no +full:- +full:pc +full:- +full:write
1 // SPDX-License-Identifier: GPL-2.0-only
11 * 2) Load a BPF filter (e.g. `tcpdump -p -n -s 0 -i eth1 host 192.168.20.0/24`)
12 * 3) Run e.g. `bpf_jit_disasm -o` to read out the last JIT code
24 #include <dis-asm.h>
41 tpath[size - 1] = 0; in get_exec_path()
54 int count, i, pc = 0; in get_asm_insns() local
86 printf("%4x:\t", pc); in get_asm_insns()
88 count = disassemble(pc, &info); in get_asm_insns()
93 printf("%02x ", (uint8_t) image[pc + i]); in get_asm_insns()
97 pc += count; in get_asm_insns()
98 } while(count > 0 && pc < len); in get_asm_insns()
146 ret = read(fd, buff, len - 1); in get_flog_buff()
202 ptr = haystack + off - (pmatch[0].rm_eo - pmatch[0].rm_so); in get_last_jit_image()
233 ulen--; in get_last_jit_image()
255 printf(" -o Also display related opcodes (default: off).\n"); in usage()
256 printf(" -O <file> Write binary image of code to file, don't disassemble to stdout.\n"); in usage()
257 printf(" -f <file> Read last image dump from file or stdin (default: klog).\n"); in usage()
258 printf(" -h Display this help.\n"); in usage()
271 while ((opt = getopt(argc, argv, "of:O:")) != -1) { in main()
284 return -1; in main()
293 return -1; in main()
298 fprintf(stderr, "No JIT image found!\n"); in main()
314 nr = write(ofd, pos, len); in main()
316 fprintf(stderr, "Could not write data to %s: ", ofile); in main()
320 len -= nr; in main()