tx_sa 320 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c struct tx_sa *t = &ipsec->tx_tbl[i]; tx_sa 695 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c struct tx_sa tsa; tx_sa 798 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c memset(&ipsec->tx_tbl[sa_idx], 0, sizeof(struct tx_sa)); tx_sa 1024 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c struct tx_sa *tsa; tx_sa 1069 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c struct tx_sa *tsa; tx_sa 1251 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c size = sizeof(struct tx_sa) * IXGBE_IPSEC_MAX_SA_COUNT; tx_sa 71 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.h struct tx_sa *tx_tbl; tx_sa 113 drivers/net/ethernet/intel/ixgbevf/ipsec.c struct tx_sa *t = &ipsec->tx_tbl[i]; tx_sa 335 drivers/net/ethernet/intel/ixgbevf/ipsec.c struct tx_sa tsa; tx_sa 409 drivers/net/ethernet/intel/ixgbevf/ipsec.c memset(&ipsec->tx_tbl[sa_idx], 0, sizeof(struct tx_sa)); tx_sa 454 drivers/net/ethernet/intel/ixgbevf/ipsec.c struct tx_sa *tsa; tx_sa 630 drivers/net/ethernet/intel/ixgbevf/ipsec.c size = sizeof(struct tx_sa) * IXGBE_IPSEC_MAX_SA_COUNT; tx_sa 54 drivers/net/ethernet/intel/ixgbevf/ipsec.h struct tx_sa *tx_tbl; tx_sa 299 drivers/net/macsec.c struct macsec_tx_sa *tx_sa; tx_sa 536 drivers/net/macsec.c static u32 tx_sa_update_pn(struct macsec_tx_sa *tx_sa, struct macsec_secy *secy) tx_sa 540 drivers/net/macsec.c spin_lock_bh(&tx_sa->lock); tx_sa 541 drivers/net/macsec.c pn = tx_sa->next_pn; tx_sa 543 drivers/net/macsec.c tx_sa->next_pn++; tx_sa 544 drivers/net/macsec.c if (tx_sa->next_pn == 0) { tx_sa 546 drivers/net/macsec.c tx_sa->active = false; tx_sa 550 drivers/net/macsec.c spin_unlock_bh(&tx_sa->lock); tx_sa 565 drivers/net/macsec.c struct macsec_tx_sa *tx_sa) tx_sa 573 drivers/net/macsec.c this_cpu_inc(tx_sa->stats->OutPktsEncrypted); tx_sa 577 drivers/net/macsec.c this_cpu_inc(tx_sa->stats->OutPktsProtected); tx_sa 599 drivers/net/macsec.c struct macsec_tx_sa *sa = macsec_skb_cb(skb)->tx_sa; tx_sa 606 drivers/net/macsec.c macsec_count_tx(skb, &macsec->secy.tx_sc, macsec_skb_cb(skb)->tx_sa); tx_sa 659 drivers/net/macsec.c struct macsec_tx_sa *tx_sa; tx_sa 668 drivers/net/macsec.c tx_sa = macsec_txsa_get(tx_sc->sa[tx_sc->encoding_sa]); tx_sa 669 drivers/net/macsec.c if (!tx_sa) { tx_sa 685 drivers/net/macsec.c macsec_txsa_put(tx_sa); tx_sa 692 drivers/net/macsec.c macsec_txsa_put(tx_sa); tx_sa 703 drivers/net/macsec.c pn = tx_sa_update_pn(tx_sa, secy); tx_sa 705 drivers/net/macsec.c macsec_txsa_put(tx_sa); tx_sa 721 drivers/net/macsec.c macsec_txsa_put(tx_sa); tx_sa 728 drivers/net/macsec.c macsec_txsa_put(tx_sa); tx_sa 733 drivers/net/macsec.c req = macsec_alloc_req(tx_sa->key.tfm, &iv, &sg, ret); tx_sa 735 drivers/net/macsec.c macsec_txsa_put(tx_sa); tx_sa 746 drivers/net/macsec.c macsec_txsa_put(tx_sa); tx_sa 762 drivers/net/macsec.c macsec_skb_cb(skb)->tx_sa = tx_sa; tx_sa 773 drivers/net/macsec.c macsec_txsa_put(tx_sa); tx_sa 779 drivers/net/macsec.c macsec_txsa_put(tx_sa); tx_sa 1430 drivers/net/macsec.c static int init_tx_sa(struct macsec_tx_sa *tx_sa, char *sak, int key_len, tx_sa 1433 drivers/net/macsec.c tx_sa->stats = alloc_percpu(struct macsec_tx_sa_stats); tx_sa 1434 drivers/net/macsec.c if (!tx_sa->stats) tx_sa 1437 drivers/net/macsec.c tx_sa->key.tfm = macsec_alloc_tfm(sak, key_len, icv_len); tx_sa 1438 drivers/net/macsec.c if (IS_ERR(tx_sa->key.tfm)) { tx_sa 1439 drivers/net/macsec.c free_percpu(tx_sa->stats); tx_sa 1440 drivers/net/macsec.c return PTR_ERR(tx_sa->key.tfm); tx_sa 1443 drivers/net/macsec.c tx_sa->active = false; tx_sa 1444 drivers/net/macsec.c refcount_set(&tx_sa->refcnt, 1); tx_sa 1445 drivers/net/macsec.c spin_lock_init(&tx_sa->lock); tx_sa 1450 drivers/net/macsec.c static void clear_tx_sa(struct macsec_tx_sa *tx_sa) tx_sa 1452 drivers/net/macsec.c tx_sa->active = false; tx_sa 1454 drivers/net/macsec.c macsec_txsa_put(tx_sa); tx_sa 1497 drivers/net/macsec.c struct macsec_tx_sa *tx_sa; tx_sa 1514 drivers/net/macsec.c tx_sa = rtnl_dereference(tx_sc->sa[*assoc_num]); tx_sa 1515 drivers/net/macsec.c if (!tx_sa) tx_sa 1521 drivers/net/macsec.c return tx_sa; tx_sa 1815 drivers/net/macsec.c struct macsec_tx_sa *tx_sa; tx_sa 1848 drivers/net/macsec.c tx_sa = rtnl_dereference(tx_sc->sa[assoc_num]); tx_sa 1849 drivers/net/macsec.c if (tx_sa) { tx_sa 1854 drivers/net/macsec.c tx_sa = kmalloc(sizeof(*tx_sa), GFP_KERNEL); tx_sa 1855 drivers/net/macsec.c if (!tx_sa) { tx_sa 1860 drivers/net/macsec.c err = init_tx_sa(tx_sa, nla_data(tb_sa[MACSEC_SA_ATTR_KEY]), tx_sa 1863 drivers/net/macsec.c kfree(tx_sa); tx_sa 1868 drivers/net/macsec.c nla_memcpy(tx_sa->key.id, tb_sa[MACSEC_SA_ATTR_KEYID], MACSEC_KEYID_LEN); tx_sa 1870 drivers/net/macsec.c spin_lock_bh(&tx_sa->lock); tx_sa 1871 drivers/net/macsec.c tx_sa->next_pn = nla_get_u32(tb_sa[MACSEC_SA_ATTR_PN]); tx_sa 1872 drivers/net/macsec.c spin_unlock_bh(&tx_sa->lock); tx_sa 1875 drivers/net/macsec.c tx_sa->active = !!nla_get_u8(tb_sa[MACSEC_SA_ATTR_ACTIVE]); tx_sa 1877 drivers/net/macsec.c if (assoc_num == tx_sc->encoding_sa && tx_sa->active) tx_sa 1880 drivers/net/macsec.c rcu_assign_pointer(tx_sc->sa[assoc_num], tx_sa); tx_sa 1974 drivers/net/macsec.c struct macsec_tx_sa *tx_sa; tx_sa 1985 drivers/net/macsec.c tx_sa = get_txsa_from_nl(genl_info_net(info), attrs, tb_sa, tx_sa 1987 drivers/net/macsec.c if (IS_ERR(tx_sa)) { tx_sa 1989 drivers/net/macsec.c return PTR_ERR(tx_sa); tx_sa 1992 drivers/net/macsec.c if (tx_sa->active) { tx_sa 1998 drivers/net/macsec.c clear_tx_sa(tx_sa); tx_sa 2032 drivers/net/macsec.c struct macsec_tx_sa *tx_sa; tx_sa 2046 drivers/net/macsec.c tx_sa = get_txsa_from_nl(genl_info_net(info), attrs, tb_sa, tx_sa 2048 drivers/net/macsec.c if (IS_ERR(tx_sa)) { tx_sa 2050 drivers/net/macsec.c return PTR_ERR(tx_sa); tx_sa 2054 drivers/net/macsec.c spin_lock_bh(&tx_sa->lock); tx_sa 2055 drivers/net/macsec.c tx_sa->next_pn = nla_get_u32(tb_sa[MACSEC_SA_ATTR_PN]); tx_sa 2056 drivers/net/macsec.c spin_unlock_bh(&tx_sa->lock); tx_sa 2060 drivers/net/macsec.c tx_sa->active = nla_get_u8(tb_sa[MACSEC_SA_ATTR_ACTIVE]); tx_sa 2063 drivers/net/macsec.c secy->operational = tx_sa->active; tx_sa 2455 drivers/net/macsec.c struct macsec_tx_sa *tx_sa = rtnl_dereference(tx_sc->sa[i]); tx_sa 2458 drivers/net/macsec.c if (!tx_sa) tx_sa 2468 drivers/net/macsec.c nla_put_u32(skb, MACSEC_SA_ATTR_PN, tx_sa->next_pn) || tx_sa 2469 drivers/net/macsec.c nla_put(skb, MACSEC_SA_ATTR_KEYID, MACSEC_KEYID_LEN, tx_sa->key.id) || tx_sa 2470 drivers/net/macsec.c nla_put_u8(skb, MACSEC_SA_ATTR_ACTIVE, tx_sa->active)) { tx_sa 2482 drivers/net/macsec.c if (copy_tx_sa_stats(skb, tx_sa->stats)) { tx_sa 2743 drivers/net/macsec.c macsec_count_tx(skb, &macsec->secy.tx_sc, macsec_skb_cb(skb)->tx_sa); tx_sa 3035 drivers/net/macsec.c struct macsec_tx_sa *tx_sa; tx_sa 3038 drivers/net/macsec.c tx_sa = rtnl_dereference(tx_sc->sa[tx_sc->encoding_sa]); tx_sa 3040 drivers/net/macsec.c secy->operational = tx_sa && tx_sa->active;