* Stop device: disable rx and tx functions to allow for reconfiguring. */
| 412 | * Stop device: disable rx and tx functions to allow for reconfiguring. |
| 413 | */ |
| 414 | int cxgbe_dev_stop(struct rte_eth_dev *eth_dev) |
| 415 | { |
| 416 | struct port_info *pi = eth_dev->data->dev_private; |
| 417 | struct adapter *adapter = pi->adapter; |
| 418 | uint16_t i; |
| 419 | |
| 420 | CXGBE_FUNC_TRACE(); |
| 421 | |
| 422 | if (!(adapter->flags & FULL_INIT_DONE)) |
| 423 | return 0; |
| 424 | |
| 425 | cxgbe_down(pi); |
| 426 | |
| 427 | /* |
| 428 | * We clear queues only if both tx and rx path of the port |
| 429 | * have been disabled |
| 430 | */ |
| 431 | t4_sge_eth_clear_queues(pi); |
| 432 | eth_dev->data->scattered_rx = 0; |
| 433 | |
| 434 | for (i = 0; i < eth_dev->data->nb_rx_queues; i++) |
| 435 | eth_dev->data->rx_queue_state[i] = RTE_ETH_QUEUE_STATE_STOPPED; |
| 436 | for (i = 0; i < eth_dev->data->nb_tx_queues; i++) |
| 437 | eth_dev->data->tx_queue_state[i] = RTE_ETH_QUEUE_STATE_STOPPED; |
| 438 | |
| 439 | return 0; |
| 440 | } |
| 441 | |
| 442 | int cxgbe_dev_configure(struct rte_eth_dev *eth_dev) |
| 443 | { |
nothing calls this directly
no test coverage detected