diff options
author | Ioana Ciocoi Radulescu <ruxandra.radulescu@nxp.com> | 2019-04-16 20:13:29 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-04-17 07:46:19 +0300 |
commit | 61f9bf0011c79323de5888470e22f4f0a7f1676f (patch) | |
tree | 794d43947afc4ddfe44d9b828d0b1ce45d172a5b /drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.h | |
parent | df8e249be866e2f762be11b14a9e7a94752614d4 (diff) | |
download | linux-61f9bf0011c79323de5888470e22f4f0a7f1676f.tar.xz |
dpaa2-eth: Add a couple of macros
Add two macros to simplify reading DPNI options.
Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.h')
-rw-r--r-- | drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.h b/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.h index a11ebfdc4a23..958955c1e322 100644 --- a/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.h +++ b/drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.h @@ -437,6 +437,12 @@ static inline int dpaa2_eth_cmp_dpni_ver(struct dpaa2_eth_priv *priv, (dpaa2_eth_cmp_dpni_ver((priv), DPNI_RX_DIST_KEY_VER_MAJOR, \ DPNI_RX_DIST_KEY_VER_MINOR) < 0) +#define dpaa2_eth_fs_enabled(priv) \ + (!((priv)->dpni_attrs.options & DPNI_OPT_NO_FS)) + +#define dpaa2_eth_fs_mask_enabled(priv) \ + ((priv)->dpni_attrs.options & DPNI_OPT_HAS_KEY_MASKING) + #define dpaa2_eth_fs_count(priv) \ ((priv)->dpni_attrs.fs_entries) |