| 248 | } |
| 249 | |
| 250 | static uint16_t |
| 251 | clb_multiwait(uint16_t port_id __rte_unused, uint16_t qidx __rte_unused, |
| 252 | struct rte_mbuf **pkts __rte_unused, uint16_t nb_rx, |
| 253 | uint16_t max_pkts __rte_unused, void *arg) |
| 254 | { |
| 255 | const unsigned int lcore = rte_lcore_id(); |
| 256 | struct queue_list_entry *queue_conf = arg; |
| 257 | struct pmd_core_cfg *lcore_conf; |
| 258 | const bool empty = nb_rx == 0; |
| 259 | |
| 260 | lcore_conf = &lcore_cfgs[lcore]; |
| 261 | |
| 262 | /* early exit */ |
| 263 | if (likely(!empty)) |
| 264 | /* early exit */ |
| 265 | queue_reset(lcore_conf, queue_conf); |
| 266 | else { |
| 267 | struct rte_power_monitor_cond pmc[lcore_conf->n_queues]; |
| 268 | int ret; |
| 269 | |
| 270 | /* can this queue sleep? */ |
| 271 | if (!queue_can_sleep(lcore_conf, queue_conf)) |
| 272 | return nb_rx; |
| 273 | |
| 274 | /* can this lcore sleep? */ |
| 275 | if (!lcore_can_sleep(lcore_conf)) |
| 276 | return nb_rx; |
| 277 | |
| 278 | /* gather all monitoring conditions */ |
| 279 | ret = get_monitor_addresses(lcore_conf, pmc, |
| 280 | lcore_conf->n_queues); |
| 281 | if (ret < 0) |
| 282 | return nb_rx; |
| 283 | |
| 284 | rte_power_monitor_multi(pmc, lcore_conf->n_queues, UINT64_MAX); |
| 285 | } |
| 286 | |
| 287 | return nb_rx; |
| 288 | } |
| 289 | |
| 290 | static uint16_t |
| 291 | clb_umwait(uint16_t port_id, uint16_t qidx, struct rte_mbuf **pkts __rte_unused, |
nothing calls this directly
no test coverage detected