| 97 | }; |
| 98 | |
| 99 | static void printUsage(const char *name) |
| 100 | { |
| 101 | fprintf(stderr, |
| 102 | "Usage: %s [-l|--listen] [-a|--address ip_address] [-p|--port port-no] [-s|--sqpoll]" |
| 103 | " [-b|--busy] [-n|--num pings] [-t|--timeout busy-poll-timeout] [-u|--prefer] [-6] [-h|--help]\n" |
| 104 | " --listen\n" |
| 105 | "-l : Server mode\n" |
| 106 | "--address\n" |
| 107 | "-a : remote or local ipv6 address\n" |
| 108 | "--busy\n" |
| 109 | "-b : busy poll io_uring instead of blocking.\n" |
| 110 | "--num_pings\n" |
| 111 | "-n : number of pings\n" |
| 112 | "--port\n" |
| 113 | "-p : port\n" |
| 114 | "--sqpoll\n" |
| 115 | "-s : Configure io_uring to use SQPOLL thread\n" |
| 116 | "--timeout\n" |
| 117 | "-t : Configure NAPI busy poll timeout" |
| 118 | "--prefer\n" |
| 119 | "-u : prefer NAPI busy poll\n" |
| 120 | "-6 : use IPV6\n" |
| 121 | "--help\n" |
| 122 | "-h : Display this usage message\n\n", |
| 123 | name); |
| 124 | } |
| 125 | |
| 126 | static void printError(const char *msg, int opt) |
| 127 | { |