]> git.baikalelectronics.ru Git - kernel.git/commit
net: mvpp2: cls: Initialize lookup priorities for all entries in the flow
authorMaxime Chevallier <maxime.chevallier@bootlin.com>
Wed, 27 Mar 2019 08:44:21 +0000 (09:44 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 27 Mar 2019 18:10:58 +0000 (11:10 -0700)
commit991d99cbe84f3a0e16fd7f204a466f9526d08d96
tree59227e89c4d898fd3d3bf2596f3126a0cf386db4
parent25c15e103293ef96ebd6960d1ffef24f7562f64d
net: mvpp2: cls: Initialize lookup priorities for all entries in the flow

When classifying a packet pertaining to a given flow, the classifier
will issue multiple lookup commands until it finds one with the 'last'
bit set. It expects all prorities to be assign continuously (although
not necessarily in an ordered fashion) from 0 to the number of lookups.

We can initialize this once, and make sure unused lookups are given an
empty port map. This avoids having to maintain priorities and the
information of which lookup is the last.

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