X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;ds=sidebyside;f=drivers%2Fnet%2Fdpaa2%2Fdpaa2_ethdev.c;h=09a11d65af93009d391511f724c46b69f4f8796a;hb=c8b34b7e9af93017747d758c64777450368384f7;hp=9daba70f5b3b55f2f1df52e9b941cc583454f3b6;hpb=c172f85ef2e5f3992ac32a2bbf6a9bc28bcc2261;p=dpdk.git diff --git a/drivers/net/dpaa2/dpaa2_ethdev.c b/drivers/net/dpaa2/dpaa2_ethdev.c index 9daba70f5b..09a11d65af 100644 --- a/drivers/net/dpaa2/dpaa2_ethdev.c +++ b/drivers/net/dpaa2/dpaa2_ethdev.c @@ -9,7 +9,7 @@ #include #include -#include +#include #include #include #include @@ -380,6 +380,22 @@ dpaa2_eth_dev_configure(struct rte_eth_dev *dev) return ret; } + /* Enabling hash results in FD requires setting DPNI_FLCTYPE_HASH in + * dpni_set_offload API. Setting this FLCTYPE for DPNI sets the FD[SC] + * to 0 for LS2 in the hardware thus disabling data/annotation + * stashing. For LX2 this is fixed in hardware and thus hash result and + * parse results can be received in FD using this option. + */ + if (dpaa2_svr_family == SVR_LX2160A) { + ret = dpni_set_offload(dpni, CMD_PRI_LOW, priv->token, + DPNI_FLCTYPE_HASH, true); + if (ret) { + PMD_INIT_LOG(ERR, "Error setting FLCTYPE: Err = %d\n", + ret); + return ret; + } + } + if (eth_conf->rxmode.hw_vlan_filter) dpaa2_vlan_offload_set(dev, ETH_VLAN_FILTER_MASK);