* Check whether given RxQ is external. * * @param dev * Pointer to Ethernet device. * @param queue_idx * Rx queue index. * * @return * True if is external RxQ, otherwise false. */
| 685 | * True if is external RxQ, otherwise false. |
| 686 | */ |
| 687 | static __rte_always_inline bool |
| 688 | mlx5_is_external_rxq(struct rte_eth_dev *dev, uint16_t queue_idx) |
| 689 | { |
| 690 | struct mlx5_priv *priv = dev->data->dev_private; |
| 691 | struct mlx5_external_rxq *rxq; |
| 692 | |
| 693 | if (!priv->ext_rxqs || queue_idx < RTE_PMD_MLX5_EXTERNAL_RX_QUEUE_ID_MIN) |
| 694 | return false; |
| 695 | rxq = &priv->ext_rxqs[queue_idx - RTE_PMD_MLX5_EXTERNAL_RX_QUEUE_ID_MIN]; |
| 696 | return !!__atomic_load_n(&rxq->refcnt, __ATOMIC_RELAXED); |
| 697 | } |
| 698 | |
| 699 | #define LWM_COOKIE_RXQID_OFFSET 0 |
| 700 | #define LWM_COOKIE_RXQID_MASK 0xffff |
no outgoing calls
no test coverage detected