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

Function eh_do_capability_check

dpdk/examples/ipsec-secgw/event_helper.c:255–284  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

253}
254
255static void
256eh_do_capability_check(struct eventmode_conf *em_conf)
257{
258 struct eventdev_params *eventdev_config;
259 int all_internal_ports = 1;
260 uint32_t eventdev_id;
261 int i;
262
263 for (i = 0; i < em_conf->nb_eventdev; i++) {
264
265 /* Get the event dev conf */
266 eventdev_config = &(em_conf->eventdev_config[i]);
267 eventdev_id = eventdev_config->eventdev_id;
268
269 /* Check if event device has internal port for Rx & Tx */
270 if (eh_dev_has_rx_internal_port(eventdev_id) &&
271 eh_dev_has_tx_internal_port(eventdev_id)) {
272 eventdev_config->all_internal_ports = 1;
273 } else {
274 all_internal_ports = 0;
275 }
276 }
277
278 /*
279 * If Rx & Tx internal ports are supported by all event devices then
280 * eth cores won't be required. Override the eth core mask requested.
281 */
282 if (all_internal_ports)
283 rte_bitmap_reset(em_conf->eth_core_mask);
284}
285
286static int
287eh_set_default_conf_link(struct eventmode_conf *em_conf)

Callers 1

eh_validate_confFunction · 0.85

Calls 3

rte_bitmap_resetFunction · 0.85

Tested by

no test coverage detected