[dpdk-dev] [PATCH v3 16/28] net/cnxk: support inline security setup for cn9k
Nithin Kumar Dabilpuram
ndabilpuram at marvell.com
Wed Oct 6 18:44:22 CEST 2021
On 10/6/21 9:51 PM, Ferruh Yigit wrote:
> On 10/1/2021 2:40 PM, Nithin Dabilpuram wrote:
>> +static int
>> +nix_security_release(struct cnxk_eth_dev *dev)
>> +{
>> + struct rte_eth_dev *eth_dev = dev->eth_dev;
>> + struct cnxk_eth_sec_sess *eth_sec, *tvar;
>> + struct roc_nix *nix = &dev->nix;
>> + int rc, ret = 0;
>> +
>> + /* Cleanup Inline inbound */
>> + if (dev->rx_offloads & DEV_RX_OFFLOAD_SECURITY) {
>> + /* Destroy inbound sessions */
>> + tvar = NULL;
>> + TAILQ_FOREACH_SAFE(eth_sec, &dev->inb.list, entry, tvar)
>> + cnxk_eth_sec_ops.session_destroy(eth_dev,
>> + eth_sec->sess);
>> +
>> + /* Clear lookup mem */
>> + cnxk_nix_lookup_mem_sa_base_clear(dev);
>> +
>> + rc = roc_nix_inl_inb_fini(nix);
>> + if (rc)
>> + plt_err("Failed to cleanup nix inline inb, rc=%d", rc);
>> + ret |= rc;
>> + }
>> +
>> + /* Cleanup Inline outbound */
>> + if (dev->tx_offloads & DEV_TX_OFFLOAD_SECURITY ||
>> + dev->rx_offloads & DEV_RX_OFFLOAD_SECURITY) {
>> + /* Destroy outbound sessions */
>> + tvar = NULL;
>> + TAILQ_FOREACH_SAFE(eth_sec, &dev->outb.list, entry, tvar)
>> + cnxk_eth_sec_ops.session_destroy(eth_dev,
>> + eth_sec->sess);
>
>
> Replacing 'TAILQ_FOREACH_SAFE' with 'RTE_TAILQ_FOREACH_SAFE' on
> next-net, because of
> following commit in the main repo:
>
> Commit f1f6ebc0eaf6 ("eal: remove sys/queue.h from public headers")
Ack, Thanks.
More information about the dev
mailing list