| 3312 | }; |
| 3313 | |
| 3314 | static void |
| 3315 | cmd_config_thresh_parsed(void *parsed_result, |
| 3316 | __rte_unused struct cmdline *cl, |
| 3317 | __rte_unused void *data) |
| 3318 | { |
| 3319 | struct cmd_config_thresh *res = parsed_result; |
| 3320 | |
| 3321 | if (!all_ports_stopped()) { |
| 3322 | fprintf(stderr, "Please stop all ports first\n"); |
| 3323 | return; |
| 3324 | } |
| 3325 | |
| 3326 | if (!strcmp(res->name, "txpt")) |
| 3327 | tx_pthresh = res->value; |
| 3328 | else if(!strcmp(res->name, "txht")) |
| 3329 | tx_hthresh = res->value; |
| 3330 | else if(!strcmp(res->name, "txwt")) |
| 3331 | tx_wthresh = res->value; |
| 3332 | else if(!strcmp(res->name, "rxpt")) |
| 3333 | rx_pthresh = res->value; |
| 3334 | else if(!strcmp(res->name, "rxht")) |
| 3335 | rx_hthresh = res->value; |
| 3336 | else if(!strcmp(res->name, "rxwt")) |
| 3337 | rx_wthresh = res->value; |
| 3338 | else { |
| 3339 | fprintf(stderr, "Unknown parameter\n"); |
| 3340 | return; |
| 3341 | } |
| 3342 | |
| 3343 | init_port_config(); |
| 3344 | |
| 3345 | cmd_reconfig_device_queue(RTE_PORT_ALL, 1, 1); |
| 3346 | } |
| 3347 | |
| 3348 | static cmdline_parse_token_string_t cmd_config_thresh_port = |
| 3349 | TOKEN_STRING_INITIALIZER(struct cmd_config_thresh, port, "port"); |
nothing calls this directly
no test coverage detected