]> git.baikalelectronics.ru Git - kernel.git/commit
net: mvpp2: cls: Support steering to RSS contexts
authorMaxime Chevallier <maxime.chevallier@bootlin.com>
Fri, 24 May 2019 10:05:54 +0000 (12:05 +0200)
committerDavid S. Miller <davem@davemloft.net>
Sat, 25 May 2019 23:38:16 +0000 (16:38 -0700)
commitaa4aefdb2f139d6e2ca95721d3ff5c0783fbff40
treef57f224b4173c8cd501cec276f6a81a8f2207be8
parentf845b663470aa19bd49416a554d54a18d5758e86
net: mvpp2: cls: Support steering to RSS contexts

When steering to an RXQ, we can perform an extra RSS step to assign a
queue from an RSS table.

This is done by setting the RSS_EN attribute in the C2 engine. In that
case, the RXQ that is assigned is the global RSS context id, that is
then translated to an RSS table using the RXQ2RSS table.

An example using ethtool to steer to RXQ 2 and 3 would be :

ethtool -X eth0 weight 0 0 1 1 context new

(This would print the allocated context id, let's say it's 1)

ethtool -N eth0 flow-type udp4 dst-port 1234 context 1 loc 0

The hash parameters are the ones that are globally configured for RSS :

ethtool -N eth0 rx-flow-hash udp4 sdfn

When an RSS context is removed while there are active classification
rules using this context, these rules are removed.

Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/mvpp2/mvpp2_cls.c