Lines Matching refs:macsec_cfg
49 static int aq_get_txsc_idx_from_secy(struct aq_macsec_cfg *macsec_cfg, in aq_get_txsc_idx_from_secy() argument
58 if (macsec_cfg->aq_txsc[i].sw_secy == secy) in aq_get_txsc_idx_from_secy()
64 static int aq_get_rxsc_idx_from_rxsc(struct aq_macsec_cfg *macsec_cfg, in aq_get_rxsc_idx_from_rxsc() argument
73 if (macsec_cfg->aq_rxsc[i].sw_rxsc == rxsc) in aq_get_rxsc_idx_from_rxsc()
307 if (nic->macsec_cfg->txsc_idx_busy & BIT(i)) in aq_mdo_dev_stop()
308 aq_clear_secy(nic, nic->macsec_cfg->aq_txsc[i].sw_secy, in aq_mdo_dev_stop()
317 struct aq_macsec_txsc *aq_txsc = &nic->macsec_cfg->aq_txsc[txsc_idx]; in aq_set_txsc()
337 tx_class_rec.sc_sa = nic->macsec_cfg->sc_sa; in aq_set_txsc()
443 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_mdo_add_secy()
482 txsc_idx = aq_get_txsc_idx_from_secy(nic->macsec_cfg, secy); in aq_mdo_upd_secy()
495 struct aq_macsec_txsc *tx_sc = &nic->macsec_cfg->aq_txsc[txsc_idx]; in aq_clear_txsc()
522 clear_bit(txsc_idx, &nic->macsec_cfg->txsc_idx_busy); in aq_clear_txsc()
523 nic->macsec_cfg->aq_txsc[txsc_idx].sw_secy = NULL; in aq_clear_txsc()
534 if (!nic->macsec_cfg) in aq_mdo_del_secy()
580 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_mdo_add_txsa()
607 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_mdo_upd_txsa()
656 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_mdo_del_txsa()
689 &nic->macsec_cfg->aq_rxsc[rxsc_idx]; in aq_set_rxsc()
708 pre_class_record.an_mask = nic->macsec_cfg->sc_sa; in aq_set_rxsc()
748 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_mdo_add_rxsc()
782 rxsc_idx = aq_get_rxsc_idx_from_rxsc(nic->macsec_cfg, ctx->rx_sc); in aq_mdo_upd_rxsc()
795 struct aq_macsec_rxsc *rx_sc = &nic->macsec_cfg->aq_rxsc[rxsc_idx]; in aq_clear_rxsc()
831 clear_bit(rxsc_idx, &nic->macsec_cfg->rxsc_idx_busy); in aq_clear_rxsc()
846 rxsc_idx = aq_get_rxsc_idx_from_rxsc(nic->macsec_cfg, ctx->rx_sc); in aq_mdo_del_rxsc()
916 rxsc_idx = aq_get_rxsc_idx_from_rxsc(nic->macsec_cfg, rx_sc); in aq_mdo_add_rxsa()
920 aq_rxsc = &nic->macsec_cfg->aq_rxsc[rxsc_idx]; in aq_mdo_add_rxsa()
938 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_mdo_upd_rxsa()
987 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_mdo_del_rxsa()
1004 struct aq_macsec_common_stats *stats = &nic->macsec_cfg->stats; in aq_mdo_get_dev_stats()
1029 txsc_idx = aq_get_txsc_idx_from_secy(nic->macsec_cfg, ctx->secy); in aq_mdo_get_tx_sc_stats()
1033 aq_txsc = &nic->macsec_cfg->aq_txsc[txsc_idx]; in aq_mdo_get_tx_sc_stats()
1048 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_mdo_get_tx_sa_stats()
1088 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_mdo_get_rx_sc_stats()
1133 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_mdo_get_rx_sa_stats()
1173 struct aq_macsec_txsc *aq_txsc = &nic->macsec_cfg->aq_txsc[txsc_idx]; in apply_txsc_cfg()
1201 struct aq_macsec_rxsc *aq_rxsc = &nic->macsec_cfg->aq_rxsc[rxsc_idx]; in apply_rxsc_cfg()
1235 txsc_idx = aq_get_txsc_idx_from_secy(nic->macsec_cfg, secy); in aq_clear_secy()
1244 rxsc_idx = aq_get_rxsc_idx_from_rxsc(nic->macsec_cfg, rx_sc); in aq_clear_secy()
1264 txsc_idx = aq_get_txsc_idx_from_secy(nic->macsec_cfg, secy); in aq_apply_secy_cfg()
1270 rxsc_idx = aq_get_rxsc_idx_from_rxsc(nic->macsec_cfg, rx_sc); in aq_apply_secy_cfg()
1288 if (nic->macsec_cfg->txsc_idx_busy & BIT(i)) { in aq_apply_macsec_cfg()
1296 if (nic->macsec_cfg->rxsc_idx_busy & BIT(i)) { in aq_apply_macsec_cfg()
1340 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_check_txsa_expiration()
1465 nic->macsec_cfg = kzalloc(sizeof(*cfg), GFP_KERNEL); in aq_macsec_init()
1466 if (!nic->macsec_cfg) in aq_macsec_init()
1478 kfree(nic->macsec_cfg); in aq_macsec_free()
1479 nic->macsec_cfg = NULL; in aq_macsec_free()
1492 if (!nic->macsec_cfg) in aq_macsec_enable()
1550 if (!nic->macsec_cfg) in aq_macsec_work()
1563 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_macsec_rx_sa_cnt()
1585 if (!nic->macsec_cfg) in aq_macsec_tx_sc_cnt()
1589 cnt = hweight_long(nic->macsec_cfg->txsc_idx_busy); in aq_macsec_tx_sc_cnt()
1597 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_macsec_tx_sa_cnt()
1617 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_macsec_update_stats()
1669 struct aq_macsec_cfg *cfg = nic->macsec_cfg; in aq_macsec_get_stats()