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

Function sfc_repr_supported

dpdk/drivers/net/sfc/sfc.c:31–48  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

29#include "sfc_nic_dma.h"
30
31bool
32sfc_repr_supported(const struct sfc_adapter *sa)
33{
34 if (!sa->switchdev)
35 return false;
36
37 /*
38 * Representor proxy should use service lcore on PF's socket
39 * (sa->socket_id) to be efficient. But the proxy will fall back
40 * to any socket if it is not possible to get the service core
41 * on the same socket. Check that at least service core on any
42 * socket is available.
43 */
44 if (sfc_get_service_lcore(SOCKET_ID_ANY) == RTE_MAX_LCORE)
45 return false;
46
47 return true;
48}
49
50bool
51sfc_repr_available(const struct sfc_adapter_shared *sas)

Callers 1

Calls 1

sfc_get_service_lcoreFunction · 0.85

Tested by

no test coverage detected