net: microchip: vcap api: Add a storage state to a VCAP rule
authorSteen Hegelund <steen.hegelund@microchip.com>
Sat, 14 Jan 2023 13:42:41 +0000 (14:42 +0100)
committerDavid S. Miller <davem@davemloft.net>
Mon, 16 Jan 2023 13:45:17 +0000 (13:45 +0000)
commit814e7693207f1bd936d600f9b5467f133e3d6e40
tree8c7120a74b7b71724e9183cf09566aae1295d6b7
parent784c3067d094dde6b7090ead51f2c9b56620409b
net: microchip: vcap api: Add a storage state to a VCAP rule

This allows a VCAP rule to be in one of 3 states:

- permanently stored in the VCAP HW (for rules that must always be present)
- enabled (stored in HW) when the corresponding lookup has been enabled
- disabled (stored in SW) when the lookup is disabled

This way important VCAP rules can be added even before the user enables the
VCAP lookups using a TC matchall filter.

Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>
Signed-off-by: Steen Hegelund <steen.hegelund@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/microchip/vcap/vcap_api.c
drivers/net/ethernet/microchip/vcap/vcap_api_debugfs.c
drivers/net/ethernet/microchip/vcap/vcap_api_debugfs_kunit.c
drivers/net/ethernet/microchip/vcap/vcap_api_private.h