/openbmc/linux/drivers/net/ethernet/mellanox/mlx5/core/esw/acl/ |
H A D | ingress_ofld.c | 10 acl_ingress_ofld_setup(struct mlx5_eswitch *esw, struct mlx5_vport *vport); 14 const struct mlx5_vport *vport) in esw_acl_ingress_prio_tag_enabled() argument 17 mlx5_eswitch_is_vf_vport(esw, vport->vport)); in esw_acl_ingress_prio_tag_enabled() 21 struct mlx5_vport *vport) in esw_acl_ingress_prio_tag_create() argument 46 if (vport->ingress.offloads.modify_metadata_rule) { in esw_acl_ingress_prio_tag_create() 48 flow_act.modify_hdr = vport->ingress.offloads.modify_metadata; in esw_acl_ingress_prio_tag_create() 51 vport->ingress.allow_rule = mlx5_add_flow_rules(vport->ingress.acl, spec, in esw_acl_ingress_prio_tag_create() 53 if (IS_ERR(vport->ingress.allow_rule)) { in esw_acl_ingress_prio_tag_create() 54 err = PTR_ERR(vport->ingress.allow_rule); in esw_acl_ingress_prio_tag_create() 56 "vport[%d] configure ingress untagged allow rule, err(%d)\n", in esw_acl_ingress_prio_tag_create() [all …]
|
H A D | egress_ofld.c | 9 static void esw_acl_egress_ofld_fwd2vport_destroy(struct mlx5_vport *vport) in esw_acl_egress_ofld_fwd2vport_destroy() argument 11 if (!vport->egress.offloads.fwd_rule) in esw_acl_egress_ofld_fwd2vport_destroy() 14 mlx5_del_flow_rules(vport->egress.offloads.fwd_rule); in esw_acl_egress_ofld_fwd2vport_destroy() 15 vport->egress.offloads.fwd_rule = NULL; in esw_acl_egress_ofld_fwd2vport_destroy() 18 void esw_acl_egress_ofld_bounce_rule_destroy(struct mlx5_vport *vport, int rule_index) in esw_acl_egress_ofld_bounce_rule_destroy() argument 21 xa_load(&vport->egress.offloads.bounce_rules, rule_index); in esw_acl_egress_ofld_bounce_rule_destroy() 27 xa_erase(&vport->egress.offloads.bounce_rules, rule_index); in esw_acl_egress_ofld_bounce_rule_destroy() 30 static void esw_acl_egress_ofld_bounce_rules_destroy(struct mlx5_vport *vport) in esw_acl_egress_ofld_bounce_rules_destroy() argument 35 xa_for_each(&vport->egress.offloads.bounce_rules, i, bounce_rule) { in esw_acl_egress_ofld_bounce_rules_destroy() 37 xa_erase(&vport->egress.offloads.bounce_rules, i); in esw_acl_egress_ofld_bounce_rules_destroy() [all …]
|
H A D | ingress_lgcy.c | 9 static void esw_acl_ingress_lgcy_rules_destroy(struct mlx5_vport *vport) in esw_acl_ingress_lgcy_rules_destroy() argument 11 if (vport->ingress.legacy.drop_rule) { in esw_acl_ingress_lgcy_rules_destroy() 12 mlx5_del_flow_rules(vport->ingress.legacy.drop_rule); in esw_acl_ingress_lgcy_rules_destroy() 13 vport->ingress.legacy.drop_rule = NULL; in esw_acl_ingress_lgcy_rules_destroy() 15 esw_acl_ingress_allow_rule_destroy(vport); in esw_acl_ingress_lgcy_rules_destroy() 19 struct mlx5_vport *vport) in esw_acl_ingress_lgcy_groups_create() argument 42 g = mlx5_create_flow_group(vport->ingress.acl, flow_group_in); in esw_acl_ingress_lgcy_groups_create() 45 esw_warn(dev, "vport[%d] ingress create untagged spoofchk flow group, err(%d)\n", in esw_acl_ingress_lgcy_groups_create() 46 vport->vport, err); in esw_acl_ingress_lgcy_groups_create() 49 vport->ingress.legacy.allow_untagged_spoofchk_grp = g; in esw_acl_ingress_lgcy_groups_create() [all …]
|
H A D | egress_lgcy.c | 9 static void esw_acl_egress_lgcy_rules_destroy(struct mlx5_vport *vport) in esw_acl_egress_lgcy_rules_destroy() argument 11 esw_acl_egress_vlan_destroy(vport); in esw_acl_egress_lgcy_rules_destroy() 12 if (!IS_ERR_OR_NULL(vport->egress.legacy.drop_rule)) { in esw_acl_egress_lgcy_rules_destroy() 13 mlx5_del_flow_rules(vport->egress.legacy.drop_rule); in esw_acl_egress_lgcy_rules_destroy() 14 vport->egress.legacy.drop_rule = NULL; in esw_acl_egress_lgcy_rules_destroy() 19 struct mlx5_vport *vport) in esw_acl_egress_lgcy_groups_create() argument 27 err = esw_acl_egress_vlan_grp_create(esw, vport); in esw_acl_egress_lgcy_groups_create() 39 drop_grp = mlx5_create_flow_group(vport->egress.acl, flow_group_in); in esw_acl_egress_lgcy_groups_create() 42 esw_warn(dev, "Failed to create E-Switch vport[%d] egress drop flow group, err(%d)\n", in esw_acl_egress_lgcy_groups_create() 43 vport->vport, err); in esw_acl_egress_lgcy_groups_create() [all …]
|
H A D | helper.c | 9 esw_acl_table_create(struct mlx5_eswitch *esw, struct mlx5_vport *vport, int ns, int size) in esw_acl_table_create() argument 26 vport_num = vport->vport; in esw_acl_table_create() 27 esw_debug(dev, "Create vport[%d] %s ACL table\n", vport_num, in esw_acl_table_create() 30 root_ns = mlx5_get_flow_vport_acl_namespace(dev, ns, vport->index); in esw_acl_table_create() 32 esw_warn(dev, "Failed to get E-Switch root namespace for vport (%d)\n", in esw_acl_table_create() 43 esw_warn(dev, "vport[%d] create %s ACL table, err(%d)\n", vport_num, in esw_acl_table_create() 50 struct mlx5_vport *vport, in esw_egress_acl_vlan_create() argument 58 if (vport->egress.allowed_vlan) in esw_egress_acl_vlan_create() 72 vport->egress.allowed_vlan = in esw_egress_acl_vlan_create() 73 mlx5_add_flow_rules(vport->egress.acl, spec, in esw_egress_acl_vlan_create() [all …]
|
/openbmc/linux/net/openvswitch/ |
H A D | vport-netdev.c | 22 #include "vport.h" 23 #include "vport-internal_dev.h" 24 #include "vport-netdev.h" 31 struct vport *vport; in netdev_port_receive() local 33 vport = ovs_netdev_get_vport(skb->dev); in netdev_port_receive() 34 if (unlikely(!vport)) in netdev_port_receive() 50 ovs_vport_receive(vport, skb, skb_tunnel_info(skb)); in netdev_port_receive() 70 struct vport *local; in get_dpdev() 76 struct vport *ovs_netdev_link(struct vport *vport, const char *name) in ovs_netdev_link() argument 80 vport->dev = dev_get_by_name(ovs_dp_get_net(vport->dp), name); in ovs_netdev_link() [all …]
|
H A D | vport.c | 21 #include "vport.h" 22 #include "vport-internal_dev.h" 31 * ovs_vport_init - initialize vport subsystem 33 * Called at module load time to initialize the vport subsystem. 46 * ovs_vport_exit - shutdown vport subsystem 48 * Called at module exit time to shutdown the vport subsystem. 95 struct vport *ovs_vport_locate(const struct net *net, const char *name) in ovs_vport_locate() 98 struct vport *vport; in ovs_vport_locate() local 100 hlist_for_each_entry_rcu(vport, bucket, hash_node, in ovs_vport_locate() 102 if (!strcmp(name, ovs_vport_name(vport)) && in ovs_vport_locate() [all …]
|
H A D | vport.h | 20 struct vport; 23 /* The following definitions are for users of the vport subsystem: */ 28 struct vport *ovs_vport_add(const struct vport_parms *); 29 void ovs_vport_del(struct vport *); 31 struct vport *ovs_vport_locate(const struct net *net, const char *name); 33 void ovs_vport_get_stats(struct vport *, struct ovs_vport_stats *); 35 int ovs_vport_get_upcall_stats(struct vport *vport, struct sk_buff *skb); 37 int ovs_vport_set_options(struct vport *, struct nlattr *options); 38 int ovs_vport_get_options(const struct vport *, struct sk_buff *); 40 int ovs_vport_set_upcall_portids(struct vport *, const struct nlattr *pids); [all …]
|
H A D | vport-internal_dev.c | 18 #include "vport-internal_dev.h" 19 #include "vport-netdev.h" 22 struct vport *vport; member 42 err = ovs_vport_receive(internal_dev_priv(netdev)->vport, skb, NULL); in internal_dev_xmit() 78 struct vport *vport = ovs_internal_dev_get_vport(dev); in internal_dev_destructor() local 80 ovs_vport_free(vport); in internal_dev_destructor() 123 static struct vport *internal_dev_create(const struct vport_parms *parms) in internal_dev_create() 125 struct vport *vport; in internal_dev_create() local 130 vport = ovs_vport_alloc(0, &ovs_internal_vport_ops, parms); in internal_dev_create() 131 if (IS_ERR(vport)) { in internal_dev_create() [all …]
|
H A D | vport-geneve.c | 24 #include "vport.h" 25 #include "vport-netdev.h" 36 static inline struct geneve_port *geneve_vport(const struct vport *vport) in geneve_vport() argument 38 return vport_priv(vport); in geneve_vport() 41 static int geneve_get_options(const struct vport *vport, in geneve_get_options() argument 44 struct geneve_port *geneve_port = geneve_vport(vport); in geneve_get_options() 51 static struct vport *geneve_tnl_create(const struct vport_parms *parms) in geneve_tnl_create() 57 struct vport *vport; in geneve_tnl_create() local 76 vport = ovs_vport_alloc(sizeof(struct geneve_port), in geneve_tnl_create() 78 if (IS_ERR(vport)) in geneve_tnl_create() [all …]
|
H A D | vport-vxlan.c | 17 #include "vport.h" 18 #include "vport-netdev.h" 22 static int vxlan_get_options(const struct vport *vport, struct sk_buff *skb) in vxlan_get_options() argument 24 struct vxlan_dev *vxlan = netdev_priv(vport->dev); in vxlan_get_options() 51 static int vxlan_configure_exts(struct vport *vport, struct nlattr *attr, in vxlan_configure_exts() argument 71 static struct vport *vxlan_tnl_create(const struct vport_parms *parms) in vxlan_tnl_create() 76 struct vport *vport; in vxlan_tnl_create() local 100 vport = ovs_vport_alloc(0, &ovs_vxlan_netdev_vport_ops, parms); in vxlan_tnl_create() 101 if (IS_ERR(vport)) in vxlan_tnl_create() 102 return vport; in vxlan_tnl_create() [all …]
|
H A D | dp_notify.c | 11 #include "vport-internal_dev.h" 12 #include "vport-netdev.h" 14 static void dp_detach_port_notify(struct vport *vport) in dp_detach_port_notify() argument 19 dp = vport->dp; in dp_detach_port_notify() 20 notify = ovs_vport_cmd_build_info(vport, ovs_dp_get_net(dp), in dp_detach_port_notify() 22 ovs_dp_detach_port(vport); in dp_detach_port_notify() 44 struct vport *vport; in ovs_dp_notify_wq() local 47 hlist_for_each_entry_safe(vport, n, &dp->ports[i], dp_hash_node) { in ovs_dp_notify_wq() 48 if (vport->ops->type == OVS_VPORT_TYPE_INTERNAL) in ovs_dp_notify_wq() 51 if (!(netif_is_ovs_port(vport->dev))) in ovs_dp_notify_wq() [all …]
|
/openbmc/linux/drivers/scsi/lpfc/ |
H A D | lpfc_vport.c | 53 inline void lpfc_vport_set_state(struct lpfc_vport *vport, in lpfc_vport_set_state() argument 56 struct fc_vport *fc_vport = vport->fc_vport; in lpfc_vport_set_state() 76 vport->port_state = LPFC_VPORT_FAILED; in lpfc_vport_set_state() 79 vport->port_state = LPFC_VPORT_UNKNOWN; in lpfc_vport_set_state() 118 lpfc_vport_sparm(struct lpfc_hba *phba, struct lpfc_vport *vport) in lpfc_vport_sparm() argument 131 rc = lpfc_read_sparam(phba, pmb, vport->vpi); in lpfc_vport_sparm() 139 * this per vport to start the FDISC. If the mailbox fails, in lpfc_vport_sparm() 146 pmb->vport = vport; in lpfc_vport_sparm() 150 lpfc_printf_vlog(vport, KERN_ERR, LOG_TRACE_EVENT, in lpfc_vport_sparm() 158 lpfc_printf_vlog(vport, KERN_ERR, LOG_TRACE_EVENT, in lpfc_vport_sparm() [all …]
|
H A D | lpfc_ct.c | 157 struct lpfc_vport *vport = ndlp->vport; in lpfc_ct_reject_event() local 158 struct lpfc_hba *phba = vport->phba; in lpfc_ct_reject_event() 241 cmdiocbq->vport = vport; in lpfc_ct_reject_event() 267 lpfc_printf_vlog(vport, KERN_ERR, LOG_ELS, in lpfc_ct_reject_event() 269 rc, vport->fc_flag); in lpfc_ct_reject_event() 286 struct lpfc_vport *vport = ctiocbq->vport; in lpfc_ct_handle_mibreq() local 294 lpfc_printf_vlog(vport, KERN_INFO, LOG_ELS, in lpfc_ct_handle_mibreq() 300 /* Ignore traffic received during vport shutdown */ in lpfc_ct_handle_mibreq() 301 if (vport->fc_flag & FC_UNLOADING) in lpfc_ct_handle_mibreq() 304 ndlp = lpfc_findnode_did(vport, did); in lpfc_ct_handle_mibreq() [all …]
|
H A D | lpfc_vmid.c | 41 * @vport: The virtual port for which this call is being executed. 47 struct lpfc_vmid *lpfc_get_vmid_from_hashtable(struct lpfc_vport *vport, in lpfc_get_vmid_from_hashtable() argument 52 hash_for_each_possible(vport->hash_table, vmp, hnode, hash) { in lpfc_get_vmid_from_hashtable() 61 * @vport: The virtual port for which this call is being executed. 69 lpfc_put_vmid_in_hashtable(struct lpfc_vport *vport, u32 hash, in lpfc_put_vmid_in_hashtable() argument 72 hash_add(vport->hash_table, &vmp->hnode, hash); in lpfc_put_vmid_in_hashtable() 102 * @vport: The virtual port for which this call is being executed. 107 static void lpfc_vmid_update_entry(struct lpfc_vport *vport, in lpfc_vmid_update_entry() argument 114 if (vport->phba->pport->vmid_flag & LPFC_VMID_TYPE_PRIO) in lpfc_vmid_update_entry() 116 else if (vport->phba->cfg_vmid_app_header) in lpfc_vmid_update_entry() [all …]
|
H A D | lpfc_els.c | 54 static void lpfc_fabric_abort_vport(struct lpfc_vport *vport); 55 static int lpfc_issue_els_fdisc(struct lpfc_vport *vport, 67 static void lpfc_init_cs_ctl_bitmap(struct lpfc_vport *vport); 68 static void lpfc_vmid_set_cs_ctl_range(struct lpfc_vport *vport, u32 min, u32 max); 69 static void lpfc_vmid_put_cs_ctl(struct lpfc_vport *vport, u32 ctcl_vmid); 72 * lpfc_els_chk_latt - Check host link attention event for a vport 73 * @vport: pointer to a host virtual N_Port data structure. 76 * attention event during the discovery process with the @vport. It is done 78 * link attention events during this @vport's discovery process, the @vport 84 * Note that, if either the host link is in state LPFC_LINK_DOWN or @vport [all …]
|
H A D | lpfc_nportdisc.c | 52 lpfc_check_adisc(struct lpfc_vport *vport, struct lpfc_nodelist *ndlp, in lpfc_check_adisc() argument 73 lpfc_check_sparm(struct lpfc_vport *vport, struct lpfc_nodelist *ndlp, in lpfc_check_sparm() argument 76 volatile struct serv_parm *hsp = &vport->fc_sparam; in lpfc_check_sparm() 155 lpfc_printf_vlog(vport, KERN_ERR, LOG_TRACE_EVENT, in lpfc_check_sparm() 226 lpfc_printf_vlog(ndlp->vport, KERN_INFO, LOG_DISCOVERY, in lpfc_els_abort() 309 rc = lpfc_els_rsp_acc(login_mbox->vport, ELS_CMD_PLOGI, in lpfc_defer_plogi_acc() 325 lpfc_rcv_plogi(struct lpfc_vport *vport, struct lpfc_nodelist *ndlp, in lpfc_rcv_plogi() argument 328 struct lpfc_hba *phba = vport->phba; in lpfc_rcv_plogi() 349 lpfc_printf_vlog(vport, KERN_ERR, LOG_TRACE_EVENT, in lpfc_rcv_plogi() 353 lpfc_els_rsp_reject(vport, stat.un.lsRjtError, cmdiocb, ndlp, in lpfc_rcv_plogi() [all …]
|
H A D | lpfc_hbadisc.c | 71 static void lpfc_disc_flush_list(struct lpfc_vport *vport); 117 if (!ndlp->vport) { in lpfc_rport_invalid() 118 pr_err("**** %s: Null vport on ndlp x%px, DID x%x rport x%px " in lpfc_rport_invalid() 131 struct lpfc_vport *vport; in lpfc_terminate_rport_io() local 138 vport = ndlp->vport; in lpfc_terminate_rport_io() 139 lpfc_debugfs_disc_trc(vport, LPFC_DISC_TRC_RPORT, in lpfc_terminate_rport_io() 144 lpfc_sli_abort_iocb(vport, ndlp->nlp_sid, 0, LPFC_CTX_TGT); in lpfc_terminate_rport_io() 154 struct lpfc_vport *vport; in lpfc_dev_loss_tmo_callbk() local 163 vport = ndlp->vport; in lpfc_dev_loss_tmo_callbk() 164 phba = vport->phba; in lpfc_dev_loss_tmo_callbk() [all …]
|
/openbmc/linux/drivers/net/ethernet/mellanox/mlx5/core/ |
H A D | eswitch.c | 37 #include <linux/mlx5/vport.h> 59 /* Vport UC/MC hash node */ 63 u16 vport; member 66 /* A flag indicating that mac was added due to mc promiscuous vport */ 109 struct mlx5_vport *vport; in mlx5_eswitch_get_vport() local 114 vport = xa_load(&esw->vports, vport_num); in mlx5_eswitch_get_vport() 115 if (!vport) { in mlx5_eswitch_get_vport() 116 esw_debug(esw->dev, "vport out of range: num(0x%x)\n", vport_num); in mlx5_eswitch_get_vport() 119 return vport; in mlx5_eswitch_get_vport() 122 static int arm_vport_context_events_cmd(struct mlx5_core_dev *dev, u16 vport, in arm_vport_context_events_cmd() argument [all …]
|
/openbmc/linux/drivers/net/ethernet/hisilicon/hns3/hns3pf/ |
H A D | hclge_mbx.c | 26 * @vport: pointer to struct hclge_vport 31 static int hclge_gen_resp_to_vf(struct hclge_vport *vport, in hclge_gen_resp_to_vf() argument 36 struct hclge_dev *hdev = vport->back; in hclge_gen_resp_to_vf() 91 static int hclge_send_mbx_msg(struct hclge_vport *vport, u8 *msg, u16 msg_len, in hclge_send_mbx_msg() argument 95 struct hclge_dev *hdev = vport->back; in hclge_send_mbx_msg() 127 static int hclge_inform_vf_reset(struct hclge_vport *vport, u16 reset_type) in hclge_inform_vf_reset() argument 132 dest_vfid = (u8)vport->vport_id; in hclge_inform_vf_reset() 136 return hclge_send_mbx_msg(vport, (u8 *)&msg_data, sizeof(msg_data), in hclge_inform_vf_reset() 140 int hclge_inform_reset_assert_to_vf(struct hclge_vport *vport) in hclge_inform_reset_assert_to_vf() argument 142 struct hclge_dev *hdev = vport->back; in hclge_inform_reset_assert_to_vf() [all …]
|
/openbmc/linux/Documentation/scsi/ |
H A D | scsi_fc_transport.rst | 57 The FC transport is now recognizing a new object - a vport. A vport is 60 be specified for the vport, with FCP_Initiator being the primary role 64 to create vports. The transport will create the vport object within the 67 on the vport, resulting in a unique <H,C,T,L> namespace for the vport. 79 up to an administrative entity controlling the vport. For example, 81 utility would be responsible for creating wwpn/wwnn's for the vport, 86 Device Trees and Vport Objects: 91 transport creates the vport object and places it under the scsi_host 93 a new scsi_host for the vport and link its object under the vport. 96 allow the parent of the vport to be something other than the scsi_host. [all …]
|
/openbmc/linux/drivers/net/ethernet/mellanox/mlx5/core/esw/ |
H A D | qos.c | 63 struct mlx5_vport *vport, in esw_qos_vport_config() argument 71 if (!vport->qos.enabled) in esw_qos_vport_config() 74 err = esw_qos_tsar_config(dev, sched_ctx, vport->qos.esw_tsar_ix, in esw_qos_vport_config() 78 "E-Switch modify TSAR vport element failed (vport=%d,err=%d)\n", in esw_qos_vport_config() 79 vport->vport, err); in esw_qos_vport_config() 80 NL_SET_ERR_MSG_MOD(extack, "E-Switch modify TSAR vport element failed"); in esw_qos_vport_config() 84 trace_mlx5_esw_vport_qos_config(vport, bw_share, max_rate); in esw_qos_vport_config() 284 struct mlx5_vport *vport; in esw_qos_set_group_max_rate() local 300 mlx5_esw_for_each_vport(esw, i, vport) { in esw_qos_set_group_max_rate() 301 if (!vport->enabled || !vport->qos.enabled || in esw_qos_set_group_max_rate() [all …]
|
H A D | devlink_port.c | 58 struct mlx5_vport *vport) in mlx5_esw_offloads_pf_vf_devlink_port_init() argument 61 u16 vport_num = vport->vport; in mlx5_esw_offloads_pf_vf_devlink_port_init() 73 vport->dl_port = dl_port; in mlx5_esw_offloads_pf_vf_devlink_port_init() 74 mlx5_devlink_port_init(dl_port, vport); in mlx5_esw_offloads_pf_vf_devlink_port_init() 79 struct mlx5_vport *vport) in mlx5_esw_offloads_pf_vf_devlink_port_cleanup() argument 81 if (!vport->dl_port) in mlx5_esw_offloads_pf_vf_devlink_port_cleanup() 84 kfree(vport->dl_port); in mlx5_esw_offloads_pf_vf_devlink_port_cleanup() 85 vport->dl_port = NULL; in mlx5_esw_offloads_pf_vf_devlink_port_cleanup() 118 int mlx5_esw_offloads_sf_devlink_port_init(struct mlx5_eswitch *esw, struct mlx5_vport *vport, in mlx5_esw_offloads_sf_devlink_port_init() argument 124 vport->dl_port = dl_port; in mlx5_esw_offloads_sf_devlink_port_init() [all …]
|
/openbmc/linux/Documentation/netlink/specs/ |
H A D | ovs_vport.yaml | 9 OVS vport configuration over generic netlink. 20 name: vport-type 22 enum-name: ovs-vport-type 23 name-prefix: ovs-vport-type- 26 name: vport-stats 28 enum-name: ovs-vport-stats 57 name: vport-options 58 enum-name: ovs-vport-options 69 enum-name: ovs-vport-upcall-attr 70 name-prefix: ovs-vport-upcall-attr- [all …]
|
/openbmc/linux/drivers/scsi/elx/libefc/ |
H A D | efc_nport.c | 18 * - a vport populates associated nport 24 * - the vport is removed 226 * If this is a vport, logout of the fabric in efc_nport_shutdown() 227 * controller so that it deletes the vport in efc_nport_shutdown() 236 efc_log_debug(efc, "[%s] nport shutdown vport, send logo\n", in efc_nport_shutdown() 258 struct efc_vport *vport; in efc_vport_link_down() local 260 /* Clear the nport reference in the vport specification */ in efc_vport_link_down() 261 list_for_each_entry(vport, &efc->vport_list, list_entry) { in efc_vport_link_down() 262 if (vport->nport == nport) { in efc_vport_link_down() 264 vport->nport = NULL; in efc_vport_link_down() [all …]
|