MCPcopy Create free account
hub / github.com/F-Stack/f-stack / queue_reset

Function queue_reset

dpdk/lib/power/rte_power_pmd_mgmt.c:189–206  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

187}
188
189static inline void
190queue_reset(struct pmd_core_cfg *cfg, struct queue_list_entry *qcfg)
191{
192 const bool is_ready_to_sleep = qcfg->n_sleeps == cfg->sleep_target;
193
194 /* reset empty poll counter for this queue */
195 qcfg->n_empty_polls = 0;
196 /* reset the queue sleep counter as well */
197 qcfg->n_sleeps = 0;
198 /* remove the queue from list of queues ready to sleep */
199 if (is_ready_to_sleep)
200 cfg->n_queues_ready_to_sleep--;
201 /*
202 * no need change the lcore sleep target counter because this lcore will
203 * reach the n_sleeps anyway, and the other cores are already counted so
204 * there's no need to do anything else.
205 */
206}
207
208static inline bool
209queue_can_sleep(struct pmd_core_cfg *cfg, struct queue_list_entry *qcfg)

Callers 3

clb_multiwaitFunction · 0.85
clb_pauseFunction · 0.85
clb_scale_freqFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected