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

Function swtim_start

dpdk/lib/eventdev/rte_event_timer_adapter.c:1069–1088  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1067}
1068
1069static int
1070swtim_start(const struct rte_event_timer_adapter *adapter)
1071{
1072 int mapped_count;
1073 struct swtim *sw = swtim_pmd_priv(adapter);
1074
1075 /* Mapping the service to more than one service core can introduce
1076 * delays while one thread is waiting to acquire a lock, so only allow
1077 * one core to be mapped to the service.
1078 *
1079 * Note: the service could be modified such that it spreads cores to
1080 * poll over multiple service instances.
1081 */
1082 mapped_count = get_mapped_count_for_service(sw->service_id);
1083
1084 if (mapped_count != 1)
1085 return mapped_count < 1 ? -ENOENT : -ENOTSUP;
1086
1087 return rte_service_component_runstate_set(sw->service_id, 1);
1088}
1089
1090static int
1091swtim_stop(const struct rte_event_timer_adapter *adapter)

Callers

nothing calls this directly

Calls 3

swtim_pmd_privFunction · 0.85

Tested by

no test coverage detected