MCPcopy Create free account
hub / github.com/F-Stack/f-stack / bnxt_allmulticast_enable_op

Function bnxt_allmulticast_enable_op

dpdk/drivers/net/bnxt/bnxt_ethdev.c:1956–1983  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1954}
1955
1956static int bnxt_allmulticast_enable_op(struct rte_eth_dev *eth_dev)
1957{
1958 struct bnxt *bp = eth_dev->data->dev_private;
1959 struct bnxt_vnic_info *vnic;
1960 uint32_t old_flags;
1961 int rc;
1962
1963 rc = is_bnxt_in_error(bp);
1964 if (rc)
1965 return rc;
1966
1967 /* Filter settings will get applied when port is started */
1968 if (!eth_dev->data->dev_started)
1969 return 0;
1970
1971 if (bp->vnic_info == NULL)
1972 return 0;
1973
1974 vnic = bnxt_get_default_vnic(bp);
1975
1976 old_flags = vnic->flags;
1977 vnic->flags |= BNXT_VNIC_INFO_ALLMULTI;
1978 rc = bnxt_hwrm_cfa_l2_set_rx_mask(bp, vnic, 0, NULL);
1979 if (rc != 0)
1980 vnic->flags = old_flags;
1981
1982 return rc;
1983}
1984
1985static int bnxt_allmulticast_disable_op(struct rte_eth_dev *eth_dev)
1986{

Callers 1

bnxt_restore_filtersFunction · 0.85

Calls 3

is_bnxt_in_errorFunction · 0.85
bnxt_get_default_vnicFunction · 0.85

Tested by

no test coverage detected