DPDK / grout

grout # a graph router based on DPDK
BSD 3-Clause "New" or "Revised" License
6 stars 3 forks source link

port: use interrupt thread to monitor link status and speed #65

Closed rjarry closed 1 week ago

rjarry commented 1 week ago

The link status behind eth ports may change at any moment. The only way to get reliable information about the link status and speed is to rely on driver notifications via the link status check interrupt thread (enabled by default in DPDK).

Configure all ports with intr_conf.lsc=1 if supported by the driver. If not supported, the link status and speed will not be updated automatically.

Register an LSC ethdev callback which only serves as a proxy to trigger a libevent callback. That way, the link status information is checked and updated from the main lcore only. libevent needs to be initialized with pthread support to allow other threads to trigger events.