Home
last modified time | relevance | path

Searched refs:secy (Results 1 – 11 of 11) sorted by relevance

/linux/drivers/net/
H A Dmacsec.c54 #define for_each_rxsc(secy, sc) \ argument
55 for (sc = rcu_dereference_bh(secy->rx_sc); \
58 #define for_each_rxsc_rtnl(secy, sc) \ argument
59 for (sc = rtnl_dereference(secy->rx_sc); \
90 * @secy: SecY config
101 struct macsec_secy secy; member
250 static sci_t macsec_active_sci(struct macsec_secy *secy) in macsec_active_sci() argument
252 struct macsec_rx_sc *rx_sc = rcu_dereference_bh(secy->rx_sc); in macsec_active_sci()
279 return macsec_active_sci(&macsec->secy); in macsec_frame_sci()
304 const struct macsec_secy *secy, u3 in macsec_fill_sectag() argument
460 __macsec_pn_wrapped(struct macsec_secy * secy,struct macsec_tx_sa * tx_sa) __macsec_pn_wrapped() argument
469 macsec_pn_wrapped(struct macsec_secy * secy,struct macsec_tx_sa * tx_sa) macsec_pn_wrapped() argument
478 tx_sa_update_pn(struct macsec_tx_sa * tx_sa,struct macsec_secy * secy) tx_sa_update_pn() argument
509 struct macsec_secy *secy = &macsec->secy; macsec_msdu_len() local
604 struct macsec_secy *secy; macsec_encrypt() local
735 macsec_post_decrypt(struct sk_buff * skb,struct macsec_secy * secy,u32 pn) macsec_post_decrypt() argument
885 macsec_decrypt(struct sk_buff * skb,struct net_device * dev,struct macsec_rx_sa * rx_sa,sci_t sci,struct macsec_secy * secy) macsec_decrypt() argument
982 find_rx_sc(struct macsec_secy * secy,sci_t sci) find_rx_sc() argument
994 find_rx_sc_rtnl(struct macsec_secy * secy,sci_t sci) find_rx_sc_rtnl() argument
1130 struct macsec_secy *secy = NULL; macsec_handle_frame() local
1436 del_rx_sc(struct macsec_secy * secy,sci_t sci) del_rx_sc() argument
1461 struct macsec_secy *secy; create_rx_sc() local
1573 struct macsec_secy *secy; get_txsa_from_nl() local
1606 struct macsec_secy *secy; get_rxsc_from_nl() local
1741 struct macsec_secy *secy; macsec_add_rxsa() local
1874 struct macsec_secy *secy; macsec_add_rxsc() local
1950 struct macsec_secy *secy; macsec_add_txsa() local
2080 struct macsec_secy *secy; macsec_del_rxsa() local
2146 struct macsec_secy *secy; macsec_del_rxsc() local
2209 struct macsec_secy *secy; macsec_del_txsa() local
2283 struct macsec_secy *secy; macsec_upd_txsa() local
2377 struct macsec_secy *secy; macsec_upd_rxsa() local
2469 struct macsec_secy *secy; macsec_upd_rxsc() local
2535 struct macsec_secy *secy = &macsec->secy; macsec_is_configured() local
2991 nla_put_secy(struct macsec_secy * secy,struct sk_buff * skb) nla_put_secy() argument
3042 dump_secy(struct macsec_secy * secy,struct net_device * dev,struct sk_buff * skb,struct netlink_callback * cb) dump_secy() argument
3290 struct macsec_secy *secy; macsec_dump_txsc() local
3430 struct macsec_secy *secy = &macsec->secy; macsec_start_xmit() local
3808 struct macsec_secy *secy; macsec_changelink_common() local
3889 struct macsec_secy secy; macsec_changelink() local
4055 struct macsec_secy *secy = &macsec->secy; macsec_add_dev() local
4325 struct macsec_secy *secy; macsec_fill_info() local
[all...]
/linux/drivers/net/ethernet/marvell/octeontx2/nic/
H A Dcn10k_macsec.c68 struct macsec_secy *secy) in cn10k_ecb_aes_encrypt()
73 if (txsc->sw_secy == secy) in cn10k_ecb_aes_encrypt()
81 struct macsec_secy *secy, in cn10k_ecb_aes_encrypt()
87 if (rxsc->sw_rxsc == rx_sc && rxsc->sw_secy == secy) in cn10k_ecb_aes_encrypt()
229 struct macsec_secy *secy, u8 hw_secy_id) in cn10k_mcs_free_rsrc()
245 policy = FIELD_PREP(MCS_RX_SECY_PLCY_RW_MASK, secy->replay_window); in cn10k_mcs_alloc_rxsa()
246 if (secy->replay_protect)
251 switch (secy->key_len) {
253 cipher = secy->xpn ? MCS_GCM_AES_XPN_128 : MCS_GCM_AES_128; in cn10k_mcs_free_rxsa()
256 cipher = secy in cn10k_mcs_free_rxsa()
97 cn10k_mcs_get_txsc(struct cn10k_mcs_cfg * cfg,struct macsec_secy * secy) cn10k_mcs_get_txsc() argument
110 cn10k_mcs_get_rxsc(struct cn10k_mcs_cfg * cfg,struct macsec_secy * secy,struct macsec_rx_sc * rx_sc) cn10k_mcs_get_rxsc() argument
258 cn10k_mcs_write_rx_secy(struct otx2_nic * pfvf,struct macsec_secy * secy,u8 hw_secy_id) cn10k_mcs_write_rx_secy() argument
313 struct macsec_secy *secy = rxsc->sw_secy; cn10k_mcs_write_rx_flowid() local
383 cn10k_mcs_write_keys(struct otx2_nic * pfvf,struct macsec_secy * secy,struct mcs_sa_plcy_write_req * req,u8 * sak,u8 * salt,ssci_t ssci) cn10k_mcs_write_keys() argument
420 cn10k_mcs_write_rx_sa_plcy(struct otx2_nic * pfvf,struct macsec_secy * secy,struct cn10k_mcs_rxsc * rxsc,u8 assoc_num,bool sa_in_use) cn10k_mcs_write_rx_sa_plcy() argument
496 cn10k_mcs_write_tx_secy(struct otx2_nic * pfvf,struct macsec_secy * secy,struct cn10k_mcs_txsc * txsc) cn10k_mcs_write_tx_secy() argument
579 cn10k_mcs_write_tx_flowid(struct otx2_nic * pfvf,struct macsec_secy * secy,struct cn10k_mcs_txsc * txsc) cn10k_mcs_write_tx_flowid() argument
625 cn10k_mcs_link_tx_sa2sc(struct otx2_nic * pfvf,struct macsec_secy * secy,struct cn10k_mcs_txsc * txsc,u8 sa_num,bool sa_active) cn10k_mcs_link_tx_sa2sc() argument
659 cn10k_mcs_write_tx_sa_plcy(struct otx2_nic * pfvf,struct macsec_secy * secy,struct cn10k_mcs_txsc * txsc,u8 assoc_num) cn10k_mcs_write_tx_sa_plcy() argument
1037 cn10k_mcs_secy_tx_cfg(struct otx2_nic * pfvf,struct macsec_secy * secy,struct cn10k_mcs_txsc * txsc,struct macsec_tx_sa * sw_tx_sa,u8 sa_num) cn10k_mcs_secy_tx_cfg() argument
1057 cn10k_mcs_secy_rx_cfg(struct otx2_nic * pfvf,struct macsec_secy * secy,u8 hw_secy_id) cn10k_mcs_secy_rx_cfg() argument
1090 cn10k_mcs_disable_rxscs(struct otx2_nic * pfvf,struct macsec_secy * secy,bool delete) cn10k_mcs_disable_rxscs() argument
1119 cn10k_mcs_sync_stats(struct otx2_nic * pfvf,struct macsec_secy * secy,struct cn10k_mcs_txsc * txsc) cn10k_mcs_sync_stats() argument
1175 struct macsec_secy *secy = ctx->secy; cn10k_mdo_open() local
1217 struct macsec_secy *secy = ctx->secy; cn10k_mdo_add_secy() local
1245 struct macsec_secy *secy = ctx->secy; cn10k_mdo_upd_secy() local
1300 struct macsec_secy *secy = ctx->secy; cn10k_mdo_add_txsa() local
1345 struct macsec_secy *secy = ctx->secy; cn10k_mdo_upd_txsa() local
1399 struct macsec_secy *secy = ctx->secy; cn10k_mdo_add_rxsc() local
1433 struct macsec_secy *secy = ctx->secy; cn10k_mdo_upd_rxsc() local
1472 struct macsec_secy *secy = ctx->secy; cn10k_mdo_add_rxsa() local
1515 struct macsec_secy *secy = ctx->secy; cn10k_mdo_upd_rxsa() local
1573 struct macsec_secy *secy = ctx->secy; cn10k_mdo_get_dev_stats() local
1652 struct macsec_secy *secy = ctx->secy; cn10k_mdo_get_rx_sc_stats() local
1743 struct macsec_secy *secy = NULL; cn10k_handle_mcs_event() local
[all...]
/linux/drivers/net/phy/
H A Dnxp-c45-tja11xx-macsec.c192 struct macsec_secy *secy; member
378 if (pos->secy->sci == sci) in nxp_c45_find_secy()
493 u32 key_size = ctx->secy->key_len / 4; in nxp_c45_sa_set_key()
506 if (ctx->secy->xpn) { in nxp_c45_sa_set_key()
616 bool end_station = phy_secy->secy->tx_sc.end_station; in nxp_c45_secy_valid()
617 bool scb = phy_secy->secy->tx_sc.scb; in nxp_c45_secy_valid()
622 if (!nxp_c45_port_is_1(phy_secy->secy->sci)) in nxp_c45_secy_valid()
645 bool end_station = phy_secy->secy->tx_sc.end_station; in nxp_c45_rx_sc0_impl()
646 bool send_sci = phy_secy->secy->tx_sc.send_sci; in nxp_c45_rx_sc0_impl()
647 bool scb = phy_secy->secy->tx_sc.scb; in nxp_c45_rx_sc0_impl()
[all …]
/linux/drivers/net/ethernet/aquantia/atlantic/
H A Daq_macsec.c32 static int aq_clear_secy(struct aq_nic_s *nic, const struct macsec_secy *secy,
36 const struct macsec_secy *secy);
50 const struct macsec_secy *secy) in aq_get_txsc_idx_from_secy() argument
54 if (unlikely(!secy)) in aq_get_txsc_idx_from_secy()
58 if (macsec_cfg->aq_txsc[i].sw_secy == secy) in aq_get_txsc_idx_from_secy()
296 ret = aq_apply_secy_cfg(nic, ctx->secy); in aq_mdo_dev_open()
319 const struct macsec_secy *secy = aq_txsc->sw_secy; in aq_set_txsc() local
325 aq_ether_addr_to_mac(tx_class_rec.mac_sa, secy->netdev->dev_addr); in aq_set_txsc()
327 put_unaligned_be64((__force u64)secy->sci, tx_class_rec.sci); in aq_set_txsc()
343 sc_rec.protect = secy->protect_frames; in aq_set_txsc()
[all …]
/linux/drivers/net/phy/mscc/
H A Dmscc_macsec.c429 if (priv->secy->replay_protect) in vsc8584_macsec_flow()
431 if (priv->secy->validate_frames == MACSEC_VALIDATE_STRICT) in vsc8584_macsec_flow()
433 else if (priv->secy->validate_frames == MACSEC_VALIDATE_CHECK) in vsc8584_macsec_flow()
436 if (priv->secy->protect_frames) in vsc8584_macsec_flow()
438 if (priv->secy->tx_sc.encrypt) in vsc8584_macsec_flow()
440 if (priv->secy->tx_sc.send_sci) in vsc8584_macsec_flow()
530 ret = vsc8584_macsec_derive_key(key, priv->secy->key_len, hkey); in vsc8584_macsec_transformation()
534 switch (priv->secy->key_len) { in vsc8584_macsec_transformation()
546 (CONTROL_TYPE_EGRESS | CONTROL_AN(priv->secy->tx_sc.encoding_sa)) : in vsc8584_macsec_transformation()
563 for (i = 0; i < priv->secy->key_len / sizeof(u32); i++) in vsc8584_macsec_transformation()
[all …]
/linux/drivers/net/ethernet/mellanox/mlx5/core/en_accel/
H A Dmacsec.c343 const struct macsec_tx_sc *tx_sc = &ctx->secy->tx_sc; in mlx5e_macsec_init_sa_fs()
387 obj_attrs.replay_window = ctx->secy->replay_window; in mlx5e_macsec_init_sa()
388 obj_attrs.replay_protect = ctx->secy->replay_protect; in mlx5e_macsec_init_sa()
434 mlx5e_macsec_cleanup_sa(macsec, rx_sa, false, ctx->secy->netdev, *fs_id); in macsec_rx_sa_active_update()
448 const struct macsec_secy *secy = ctx->secy; in mlx5e_macsec_secy_features_validate() local
450 if (secy->validate_frames != MACSEC_VALIDATE_STRICT) { in mlx5e_macsec_secy_features_validate()
456 if (secy->icv_len != MACSEC_DEFAULT_ICV_LEN) { in mlx5e_macsec_secy_features_validate()
462 if (!secy->protect_frames) { in mlx5e_macsec_secy_features_validate()
468 if (!ctx->secy->tx_sc.encrypt) { in mlx5e_macsec_secy_features_validate()
485 if (iter->netdev == ctx->secy->netdev) in mlx5e_macsec_get_macsec_device_context()
[all …]
/linux/drivers/net/ethernet/marvell/octeontx2/af/
H A Dmcs.c310 for (id = 0; id < map->secy.max; id++) { in mcs_clear_all_stats()
317 for (id = 0; id < map->secy.max; id++) { in mcs_clear_all_stats()
406 void mcs_rx_sc_cam_write(struct mcs *mcs, u64 sci, u64 secy, int sc_id) in mcs_rx_sc_cam_write() argument
409 mcs_reg_write(mcs, MCSX_CPM_RX_SLAVE_SC_CAMX(1, sc_id), secy); in mcs_rx_sc_cam_write()
433 val = (map->secy & 0x7F) | (map->ctrl_pkt & 0x1) << 8; in cn10kb_mcs_flowid_secy_map()
514 __set_bit(secy_id, mcs->rx.secy.bmap); in mcs_install_flowid_bypass_entry()
515 __set_bit(secy_id, mcs->tx.secy.bmap); in mcs_install_flowid_bypass_entry()
530 map.secy = secy_id; in mcs_install_flowid_bypass_entry()
732 for (id = 0; id < map->secy.max; id++) { in mcs_free_all_rsrc()
735 mcs_free_rsrc(&map->secy, map->secy2pf_map, in mcs_free_all_rsrc()
[all …]
H A Dmcs.h102 u8 secy; member
116 struct rsrc_bmap secy; member
191 void mcs_rx_sc_cam_write(struct mcs *mcs, u64 sci, u64 secy, int sc_id);
H A Dmcs_rvu_if.c617 map.secy = req->secy_id; in rvu_mbox_handler_mcs_flowid_entry_write()
661 rc = mcs_free_rsrc(&map->secy, map->secy2pf_map, req->rsrc_id, pcifunc); in rvu_mbox_handler_mcs_free_resources()
722 rsrc_id = mcs_alloc_rsrc(&map->secy, map->secy2pf_map, pcifunc); in rvu_mbox_handler_mcs_alloc_resources()
H A Dmcs_cnf10kb.c77 val = (map->secy & 0x3F) | (map->ctrl_pkt & 0x1) << 6; in cnf10kb_mcs_flowid_secy_map()
/linux/drivers/net/ethernet/mellanox/mlx5/core/lib/
H A Dmacsec_fs.c610 const struct macsec_secy *secy = ctx->secy; in macsec_fs_tx_create_sectag_header() local
611 bool sci_present = macsec_send_sci(secy); in macsec_fs_tx_create_sectag_header()
615 tx_sc = &secy->tx_sc; in macsec_fs_tx_create_sectag_header()
620 memcpy(&sectag.sci, &secy->sci, in macsec_fs_tx_create_sectag_header()
632 else if (secy->icv_len != MACSEC_DEFAULT_ICV_LEN) in macsec_fs_tx_create_sectag_header()
875 err = macsec_fs_id_add(&macsec_fs->macsec_devices_list, *fs_id, macsec_ctx->secy->netdev, in macsec_fs_tx_add_rule()
885 macsec_fs_tx_del_rule(macsec_fs, tx_rule, macsec_ctx->secy->netdev); in macsec_fs_tx_add_rule()
1824 err = macsec_fs_id_add(&macsec_fs->macsec_devices_list, fs_id, macsec_ctx->secy->netdev, in macsec_fs_rx_add_rule()
1835 macsec_fs_rx_del_rule(macsec_fs, rx_rule, macsec_ctx->secy->netdev, fs_id); in macsec_fs_rx_add_rule()
2084 .macdev = macsec_ctx->secy->netdev, in mlx5_macsec_fs_add_rule()