struct aq_nic_s *nic = netdev_priv(ctx->netdev);
int ret = 0;
- if (ctx->prepare)
- return 0;
-
if (netif_carrier_ok(nic->ndev))
ret = aq_apply_secy_cfg(nic, ctx->secy);
struct aq_nic_s *nic = netdev_priv(ctx->netdev);
int i;
- if (ctx->prepare)
- return 0;
-
for (i = 0; i < AQ_MACSEC_MAX_SC; i++) {
if (nic->macsec_cfg->txsc_idx_busy & BIT(i))
aq_clear_secy(nic, nic->macsec_cfg->aq_txsc[i].sw_secy,
u32 txsc_idx;
int ret = 0;
- if (ctx->prepare)
- return 0;
-
if (secy->xpn)
return -EOPNOTSUPP;
int txsc_idx;
int ret = 0;
- if (ctx->prepare)
- return 0;
-
txsc_idx = aq_get_txsc_idx_from_secy(nic->macsec_cfg, secy);
if (txsc_idx < 0)
return -ENOENT;
struct aq_nic_s *nic = netdev_priv(ctx->netdev);
int ret = 0;
- if (ctx->prepare)
- return 0;
-
if (!nic->macsec_cfg)
return 0;
int txsc_idx;
int ret = 0;
- if (ctx->prepare)
- return 0;
-
txsc_idx = aq_get_txsc_idx_from_secy(cfg, secy);
if (txsc_idx < 0)
return -EINVAL;
int txsc_idx;
int ret = 0;
- if (ctx->prepare)
- return 0;
-
txsc_idx = aq_get_txsc_idx_from_secy(cfg, secy);
if (txsc_idx < 0)
return -EINVAL;
int txsc_idx;
int ret = 0;
- if (ctx->prepare)
- return 0;
-
txsc_idx = aq_get_txsc_idx_from_secy(cfg, ctx->secy);
if (txsc_idx < 0)
return -EINVAL;
u32 rxsc_idx;
int ret = 0;
- if (ctx->prepare)
- return 0;
-
if (hweight32(cfg->rxsc_idx_busy) >= rxsc_idx_max)
return -ENOSPC;
int rxsc_idx;
int ret = 0;
- if (ctx->prepare)
- return 0;
-
rxsc_idx = aq_get_rxsc_idx_from_rxsc(nic->macsec_cfg, ctx->rx_sc);
if (rxsc_idx < 0)
return -ENOENT;
int rxsc_idx;
int ret = 0;
- if (ctx->prepare)
- return 0;
-
rxsc_idx = aq_get_rxsc_idx_from_rxsc(nic->macsec_cfg, ctx->rx_sc);
if (rxsc_idx < 0)
return -ENOENT;
int rxsc_idx;
int ret = 0;
- if (ctx->prepare)
- return 0;
-
rxsc_idx = aq_get_rxsc_idx_from_rxsc(nic->macsec_cfg, rx_sc);
if (rxsc_idx < 0)
return -EINVAL;
int rxsc_idx;
int ret = 0;
- if (ctx->prepare)
- return 0;
-
rxsc_idx = aq_get_rxsc_idx_from_rxsc(cfg, rx_sc);
if (rxsc_idx < 0)
return -EINVAL;
int rxsc_idx;
int ret = 0;
- if (ctx->prepare)
- return 0;
-
rxsc_idx = aq_get_rxsc_idx_from_rxsc(cfg, rx_sc);
if (rxsc_idx < 0)
return -EINVAL;
struct aq_macsec_common_stats *stats = &nic->macsec_cfg->stats;
struct aq_hw_s *hw = nic->aq_hw;
- if (ctx->prepare)
- return 0;
-
aq_get_macsec_common_stats(hw, stats);
ctx->stats.dev_stats->OutPktsUntagged = stats->out.untagged_pkts;
struct aq_macsec_txsc *aq_txsc;
int txsc_idx;
- if (ctx->prepare)
- return 0;
-
txsc_idx = aq_get_txsc_idx_from_secy(nic->macsec_cfg, ctx->secy);
if (txsc_idx < 0)
return -ENOENT;
u32 next_pn;
int ret;
- if (ctx->prepare)
- return 0;
-
txsc_idx = aq_get_txsc_idx_from_secy(cfg, ctx->secy);
if (txsc_idx < 0)
return -EINVAL;
int ret = 0;
int i;
- if (ctx->prepare)
- return 0;
-
rxsc_idx = aq_get_rxsc_idx_from_rxsc(cfg, ctx->rx_sc);
if (rxsc_idx < 0)
return -ENOENT;
u32 next_pn;
int ret;
- if (ctx->prepare)
- return 0;
-
rxsc_idx = aq_get_rxsc_idx_from_rxsc(cfg, ctx->rx_sc);
if (rxsc_idx < 0)
return -EINVAL;