OSDN Git Service

dpaa2-eth: Configure Rx flow classification key
authorIoana Radulescu <ruxandra.radulescu@nxp.com>
Mon, 1 Oct 2018 10:44:57 +0000 (13:44 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 3 Oct 2018 05:24:08 +0000 (22:24 -0700)
commit4aaaf9b95abad9cfcd2ac9b07797bccdd4ec01c1
treef5079bee2586c0a5a37519da6f306ff2cbbd0134
parentf76c483a0b373fdfaedafefe8e4da8beb614e1e9
dpaa2-eth: Configure Rx flow classification key

For firmware versions that support it, configure an Rx flow
classification key at probe time.

Hardware expects all rules in the classification table to share
the same key. So we setup a key containing all supported fields
at driver init and when a user adds classification rules through
ethtool, we will just mask out the unused header fields.

Since the key composition process is the same for flow
classification and hashing, reuse existing code where possible.

Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c
drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.h
drivers/net/ethernet/freescale/dpaa2/dpni-cmd.h
drivers/net/ethernet/freescale/dpaa2/dpni.c
drivers/net/ethernet/freescale/dpaa2/dpni.h