rx_sa 319 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c struct rx_sa *r = &ipsec->rx_tbl[i]; rx_sa 396 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c struct rx_sa *rsa; rx_sa 584 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c struct rx_sa rsa; rx_sa 756 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c struct rx_sa *rsa; rx_sa 786 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c memset(rsa, 0, sizeof(struct rx_sa)); rx_sa 1002 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c struct rx_sa *rsa; rx_sa 1246 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c size = sizeof(struct rx_sa) * IXGBE_IPSEC_MAX_SA_COUNT; rx_sa 70 drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.h struct rx_sa *rx_tbl; rx_sa 112 drivers/net/ethernet/intel/ixgbevf/ipsec.c struct rx_sa *r = &ipsec->rx_tbl[i]; rx_sa 183 drivers/net/ethernet/intel/ixgbevf/ipsec.c struct rx_sa *rsa; rx_sa 276 drivers/net/ethernet/intel/ixgbevf/ipsec.c struct rx_sa rsa; rx_sa 397 drivers/net/ethernet/intel/ixgbevf/ipsec.c memset(&ipsec->rx_tbl[sa_idx], 0, sizeof(struct rx_sa)); rx_sa 625 drivers/net/ethernet/intel/ixgbevf/ipsec.c size = sizeof(struct rx_sa) * IXGBE_IPSEC_MAX_SA_COUNT; rx_sa 53 drivers/net/ethernet/intel/ixgbevf/ipsec.h struct rx_sa *rx_tbl; rx_sa 300 drivers/net/macsec.c struct macsec_rx_sa *rx_sa; rx_sa 786 drivers/net/macsec.c struct macsec_rx_sa *rx_sa = macsec_skb_cb(skb)->rx_sa; rx_sa 787 drivers/net/macsec.c struct pcpu_rx_sc_stats *rxsc_stats = this_cpu_ptr(rx_sa->sc->stats); rx_sa 791 drivers/net/macsec.c spin_lock(&rx_sa->lock); rx_sa 792 drivers/net/macsec.c if (rx_sa->next_pn >= secy->replay_window) rx_sa 793 drivers/net/macsec.c lowest_pn = rx_sa->next_pn - secy->replay_window; rx_sa 799 drivers/net/macsec.c spin_unlock(&rx_sa->lock); rx_sa 816 drivers/net/macsec.c spin_unlock(&rx_sa->lock); rx_sa 830 drivers/net/macsec.c this_cpu_inc(rx_sa->stats->InPktsInvalid); rx_sa 843 drivers/net/macsec.c this_cpu_inc(rx_sa->stats->InPktsOK); rx_sa 847 drivers/net/macsec.c if (pn >= rx_sa->next_pn) rx_sa 848 drivers/net/macsec.c rx_sa->next_pn = pn + 1; rx_sa 849 drivers/net/macsec.c spin_unlock(&rx_sa->lock); rx_sa 889 drivers/net/macsec.c struct macsec_rx_sa *rx_sa = macsec_skb_cb(skb)->rx_sa; rx_sa 890 drivers/net/macsec.c struct macsec_rx_sc *rx_sc = rx_sa->sc; rx_sa 918 drivers/net/macsec.c macsec_rxsa_put(rx_sa); rx_sa 925 drivers/net/macsec.c struct macsec_rx_sa *rx_sa, rx_sa 947 drivers/net/macsec.c req = macsec_alloc_req(rx_sa->key.tfm, &iv, &sg, ret); rx_sa 1080 drivers/net/macsec.c struct macsec_rx_sa *rx_sa; rx_sa 1166 drivers/net/macsec.c rx_sa = macsec_rxsa_get(rx_sc->sa[macsec_skb_cb(skb)->assoc_num]); rx_sa 1167 drivers/net/macsec.c if (!rx_sa) { rx_sa 1195 drivers/net/macsec.c spin_lock(&rx_sa->lock); rx_sa 1196 drivers/net/macsec.c late = rx_sa->next_pn >= secy->replay_window && rx_sa 1197 drivers/net/macsec.c pn < (rx_sa->next_pn - secy->replay_window); rx_sa 1198 drivers/net/macsec.c spin_unlock(&rx_sa->lock); rx_sa 1208 drivers/net/macsec.c macsec_skb_cb(skb)->rx_sa = rx_sa; rx_sa 1213 drivers/net/macsec.c skb = macsec_decrypt(skb, dev, rx_sa, sci, secy); rx_sa 1218 drivers/net/macsec.c macsec_rxsa_put(rx_sa); rx_sa 1234 drivers/net/macsec.c if (rx_sa) rx_sa 1235 drivers/net/macsec.c macsec_rxsa_put(rx_sa); rx_sa 1251 drivers/net/macsec.c macsec_rxsa_put(rx_sa); rx_sa 1332 drivers/net/macsec.c static int init_rx_sa(struct macsec_rx_sa *rx_sa, char *sak, int key_len, rx_sa 1335 drivers/net/macsec.c rx_sa->stats = alloc_percpu(struct macsec_rx_sa_stats); rx_sa 1336 drivers/net/macsec.c if (!rx_sa->stats) rx_sa 1339 drivers/net/macsec.c rx_sa->key.tfm = macsec_alloc_tfm(sak, key_len, icv_len); rx_sa 1340 drivers/net/macsec.c if (IS_ERR(rx_sa->key.tfm)) { rx_sa 1341 drivers/net/macsec.c free_percpu(rx_sa->stats); rx_sa 1342 drivers/net/macsec.c return PTR_ERR(rx_sa->key.tfm); rx_sa 1345 drivers/net/macsec.c rx_sa->active = false; rx_sa 1346 drivers/net/macsec.c rx_sa->next_pn = 1; rx_sa 1347 drivers/net/macsec.c refcount_set(&rx_sa->refcnt, 1); rx_sa 1348 drivers/net/macsec.c spin_lock_init(&rx_sa->lock); rx_sa 1353 drivers/net/macsec.c static void clear_rx_sa(struct macsec_rx_sa *rx_sa) rx_sa 1355 drivers/net/macsec.c rx_sa->active = false; rx_sa 1357 drivers/net/macsec.c macsec_rxsa_put(rx_sa); rx_sa 1565 drivers/net/macsec.c struct macsec_rx_sa *rx_sa; rx_sa 1578 drivers/net/macsec.c rx_sa = rtnl_dereference(rx_sc->sa[*assoc_num]); rx_sa 1579 drivers/net/macsec.c if (!rx_sa) rx_sa 1583 drivers/net/macsec.c return rx_sa; rx_sa 1659 drivers/net/macsec.c struct macsec_rx_sa *rx_sa; rx_sa 1693 drivers/net/macsec.c rx_sa = rtnl_dereference(rx_sc->sa[assoc_num]); rx_sa 1694 drivers/net/macsec.c if (rx_sa) { rx_sa 1699 drivers/net/macsec.c rx_sa = kmalloc(sizeof(*rx_sa), GFP_KERNEL); rx_sa 1700 drivers/net/macsec.c if (!rx_sa) { rx_sa 1705 drivers/net/macsec.c err = init_rx_sa(rx_sa, nla_data(tb_sa[MACSEC_SA_ATTR_KEY]), rx_sa 1708 drivers/net/macsec.c kfree(rx_sa); rx_sa 1714 drivers/net/macsec.c spin_lock_bh(&rx_sa->lock); rx_sa 1715 drivers/net/macsec.c rx_sa->next_pn = nla_get_u32(tb_sa[MACSEC_SA_ATTR_PN]); rx_sa 1716 drivers/net/macsec.c spin_unlock_bh(&rx_sa->lock); rx_sa 1720 drivers/net/macsec.c rx_sa->active = !!nla_get_u8(tb_sa[MACSEC_SA_ATTR_ACTIVE]); rx_sa 1722 drivers/net/macsec.c nla_memcpy(rx_sa->key.id, tb_sa[MACSEC_SA_ATTR_KEYID], MACSEC_KEYID_LEN); rx_sa 1723 drivers/net/macsec.c rx_sa->sc = rx_sc; rx_sa 1724 drivers/net/macsec.c rcu_assign_pointer(rx_sc->sa[assoc_num], rx_sa); rx_sa 1893 drivers/net/macsec.c struct macsec_rx_sa *rx_sa; rx_sa 1908 drivers/net/macsec.c rx_sa = get_rxsa_from_nl(genl_info_net(info), attrs, tb_rxsc, tb_sa, rx_sa 1910 drivers/net/macsec.c if (IS_ERR(rx_sa)) { rx_sa 1912 drivers/net/macsec.c return PTR_ERR(rx_sa); rx_sa 1915 drivers/net/macsec.c if (rx_sa->active) { rx_sa 1921 drivers/net/macsec.c clear_rx_sa(rx_sa); rx_sa 2076 drivers/net/macsec.c struct macsec_rx_sa *rx_sa; rx_sa 2094 drivers/net/macsec.c rx_sa = get_rxsa_from_nl(genl_info_net(info), attrs, tb_rxsc, tb_sa, rx_sa 2096 drivers/net/macsec.c if (IS_ERR(rx_sa)) { rx_sa 2098 drivers/net/macsec.c return PTR_ERR(rx_sa); rx_sa 2102 drivers/net/macsec.c spin_lock_bh(&rx_sa->lock); rx_sa 2103 drivers/net/macsec.c rx_sa->next_pn = nla_get_u32(tb_sa[MACSEC_SA_ATTR_PN]); rx_sa 2104 drivers/net/macsec.c spin_unlock_bh(&rx_sa->lock); rx_sa 2108 drivers/net/macsec.c rx_sa->active = nla_get_u8(tb_sa[MACSEC_SA_ATTR_ACTIVE]); rx_sa 2540 drivers/net/macsec.c struct macsec_rx_sa *rx_sa = rtnl_dereference(rx_sc->sa[i]); rx_sa 2543 drivers/net/macsec.c if (!rx_sa) rx_sa 2562 drivers/net/macsec.c if (copy_rx_sa_stats(skb, rx_sa->stats)) { rx_sa 2572 drivers/net/macsec.c nla_put_u32(skb, MACSEC_SA_ATTR_PN, rx_sa->next_pn) || rx_sa 2573 drivers/net/macsec.c nla_put(skb, MACSEC_SA_ATTR_KEYID, MACSEC_KEYID_LEN, rx_sa->key.id) || rx_sa 2574 drivers/net/macsec.c nla_put_u8(skb, MACSEC_SA_ATTR_ACTIVE, rx_sa->active)) {