]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum: Add packet traps for BFD packets
authorIdo Schimmel <idosch@mellanox.com>
Mon, 25 May 2020 23:05:55 +0000 (02:05 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 27 May 2020 03:33:58 +0000 (20:33 -0700)
commitd8624d00802262e67cc35a456edc4df2a8163f34
tree64e01ee5343b3f823b040e1e81a947d21e8afbde
parent3aa9efd8710c8b83e3e8509d8b6822ce4f94efe7
mlxsw: spectrum: Add packet traps for BFD packets

Bidirectional Forwarding Detection (BFD) provides "low-overhead,
short-duration detection of failures in the path between adjacent
forwarding engines" (RFC 5880).

This is accomplished by exchanging BFD packets between the two
forwarding engines. Up until now these packets were trapped via the
general local delivery (i.e., IP2ME) trap which also traps a lot of
other packets that are not as time-sensitive as BFD packets.

Expose dedicated traps for BFD packets so that user space could
configure a dedicated policer for them.

Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Reviewed-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/reg.h
drivers/net/ethernet/mellanox/mlxsw/spectrum.c
drivers/net/ethernet/mellanox/mlxsw/trap.h