/Linux-v4.19/drivers/target/tcm_fc/ |
D | tfc_conf.c | 57 static ssize_t ft_parse_wwn(const char *name, u64 *wwn, int strict) in ft_parse_wwn() argument 66 *wwn = 0; in ft_parse_wwn() 88 *wwn = (*wwn << 4) | val; in ft_parse_wwn() 97 ssize_t ft_format_wwn(char *buf, size_t len, u64 wwn) in ft_format_wwn() argument 101 put_unaligned_be64(wwn, b); in ft_format_wwn() 109 u64 *wwn = arg; in ft_wwn_show() local 112 len = ft_format_wwn(buf, PAGE_SIZE - 2, *wwn); in ft_wwn_show() 120 u64 wwn; in ft_wwn_store() local 122 ret = ft_parse_wwn(buf, &wwn, 0); in ft_wwn_store() 124 *(u64 *)arg = wwn; in ft_wwn_store() [all …]
|
/Linux-v4.19/drivers/scsi/lpfc/ |
D | lpfc_vport.c | 183 lpfc_valid_wwn_format(struct lpfc_hba *phba, struct lpfc_name *wwn, in lpfc_valid_wwn_format() argument 189 if (!((wwn->u.wwn[0] >> 4) == 1 && in lpfc_valid_wwn_format() 190 ((wwn->u.wwn[0] & 0xf) != 0 || (wwn->u.wwn[1] & 0xf) != 0))) in lpfc_valid_wwn_format() 197 wwn->u.wwn[0], wwn->u.wwn[1], in lpfc_valid_wwn_format() 198 wwn->u.wwn[2], wwn->u.wwn[3], in lpfc_valid_wwn_format() 199 wwn->u.wwn[4], wwn->u.wwn[5], in lpfc_valid_wwn_format() 200 wwn->u.wwn[6], wwn->u.wwn[7]); in lpfc_valid_wwn_format() 373 u64_to_wwn(fc_vport->node_name, vport->fc_nodename.u.wwn); in lpfc_vport_create() 374 u64_to_wwn(fc_vport->port_name, vport->fc_portname.u.wwn); in lpfc_vport_create() 376 memcpy(&vport->fc_sparam.portName, vport->fc_portname.u.wwn, 8); in lpfc_vport_create() [all …]
|
D | lpfc_nportdisc.c | 162 sp->nodeName.u.wwn[0], sp->nodeName.u.wwn[1], in lpfc_check_sparm() 163 sp->nodeName.u.wwn[2], sp->nodeName.u.wwn[3], in lpfc_check_sparm() 164 sp->nodeName.u.wwn[4], sp->nodeName.u.wwn[5], in lpfc_check_sparm() 165 sp->nodeName.u.wwn[6], sp->nodeName.u.wwn[7]); in lpfc_check_sparm() 303 if (wwn_to_u64(sp->portName.u.wwn) == 0) { in lpfc_rcv_plogi() 312 if (wwn_to_u64(sp->nodeName.u.wwn) == 0) { in lpfc_rcv_plogi() 322 nlp_portwwn = wwn_to_u64(ndlp->nlp_portname.u.wwn); in lpfc_rcv_plogi() 378 nlp_portwwn != wwn_to_u64(sp->portName.u.wwn)) in lpfc_rcv_plogi() 385 wwn_to_u64(sp->portName.u.wwn)); in lpfc_rcv_plogi() 1146 (wwn_to_u64(sp->portName.u.wwn) == 0 || in lpfc_cmpl_plogi_plogi_issue() [all …]
|
D | lpfc_mbox.c | 903 memcpy(mb->un.varRegVpi.wwn, &vport->fc_portname, in lpfc_reg_vpi() 905 mb->un.varRegVpi.wwn[0] = cpu_to_le32(mb->un.varRegVpi.wwn[0]); in lpfc_reg_vpi() 906 mb->un.varRegVpi.wwn[1] = cpu_to_le32(mb->un.varRegVpi.wwn[1]); in lpfc_reg_vpi() 2161 memcpy(reg_vfi->wwn, &vport->fc_portname, sizeof(struct lpfc_name)); in lpfc_reg_vfi() 2162 reg_vfi->wwn[0] = cpu_to_le32(reg_vfi->wwn[0]); in lpfc_reg_vfi() 2163 reg_vfi->wwn[1] = cpu_to_le32(reg_vfi->wwn[1]); in lpfc_reg_vfi() 2209 reg_vfi->wwn[0], reg_vfi->wwn[1], vport->fc_flag, in lpfc_reg_vfi()
|
D | lpfc_scsi.c | 1370 if (phba->lpfc_injerr_wwpn.u.wwn[0] && in lpfc_bg_err_inject() 4592 ndlp->nlp_nodename.u.wwn[0], in lpfc_queuecommand() 4593 ndlp->nlp_nodename.u.wwn[1], in lpfc_queuecommand() 4594 ndlp->nlp_nodename.u.wwn[2], in lpfc_queuecommand() 4595 ndlp->nlp_nodename.u.wwn[3], in lpfc_queuecommand() 4596 ndlp->nlp_nodename.u.wwn[4], in lpfc_queuecommand() 4597 ndlp->nlp_nodename.u.wwn[5], in lpfc_queuecommand() 4598 ndlp->nlp_nodename.u.wwn[6], in lpfc_queuecommand() 4599 ndlp->nlp_nodename.u.wwn[7], in lpfc_queuecommand() 4600 ndlp->nlp_portname.u.wwn[0], in lpfc_queuecommand() [all …]
|
D | lpfc_attr.c | 174 wwn_to_u64(vport->fc_portname.u.wwn)); in lpfc_nvme_info_show() 192 wwn_to_u64(vport->fc_portname.u.wwn), in lpfc_nvme_info_show() 193 wwn_to_u64(vport->fc_nodename.u.wwn), in lpfc_nvme_info_show() 328 wwn_to_u64(vport->fc_portname.u.wwn)); in lpfc_nvme_info_show() 356 wwn_to_u64(vport->fc_portname.u.wwn), in lpfc_nvme_info_show() 357 wwn_to_u64(vport->fc_nodename.u.wwn), in lpfc_nvme_info_show() 2446 lpfc_wwn_set(const char *buf, size_t cnt, char wwn[]) in lpfc_wwn_set() argument 2458 memset(wwn, 0, WWN_SZ); in lpfc_wwn_set() 2471 wwn[i/2] = j & 0xff; in lpfc_wwn_set() 4188 ndlp->nlp_portname.u.wwn[0], in sysfs_drvr_stat_data_read() [all …]
|
D | lpfc_init.c | 350 vport->fc_sparam.nodeName.u.wwn); in lpfc_update_vport_wwn() 353 vport->fc_sparam.portName.u.wwn); in lpfc_update_vport_wwn() 359 if (vport->fc_nodename.u.wwn[0] == 0 || vport->phba->cfg_soft_wwnn) in lpfc_update_vport_wwn() 370 if (vport->fc_portname.u.wwn[0] != 0 && in lpfc_update_vport_wwn() 375 if (vport->fc_portname.u.wwn[0] == 0 || in lpfc_update_vport_wwn() 462 fc_host_node_name(shost) = wwn_to_u64(vport->fc_nodename.u.wwn); in lpfc_config_port_post() 463 fc_host_port_name(shost) = wwn_to_u64(vport->fc_portname.u.wwn); in lpfc_config_port_post() 3738 uint64_t wwn; in lpfc_get_wwpn() local 3761 memcpy(&wwn, (char *)mb->un.varRDnvp.portname, sizeof(uint64_t)); in lpfc_get_wwpn() 3765 return be64_to_cpu(wwn); in lpfc_get_wwpn() [all …]
|
/Linux-v4.19/drivers/target/ |
D | target_core_fabric_configfs.c | 816 struct se_wwn *wwn = se_tpg->se_tpg_wwn; in target_fabric_tpg_release() local 817 struct target_fabric_configfs *tf = wwn->wwn_tf; in target_fabric_tpg_release() 836 struct se_wwn *wwn = container_of(group, struct se_wwn, wwn_group); in target_fabric_make_tpg() local 837 struct target_fabric_configfs *tf = wwn->wwn_tf; in target_fabric_make_tpg() 845 se_tpg = tf->tf_ops->fabric_make_tpg(wwn, name); in target_fabric_make_tpg() 898 struct se_wwn *wwn = container_of(to_config_group(item), in target_fabric_release_wwn() local 900 struct target_fabric_configfs *tf = wwn->wwn_tf; in target_fabric_release_wwn() 902 configfs_remove_default_groups(&wwn->fabric_stat_group); in target_fabric_release_wwn() 903 tf->tf_ops->fabric_drop_wwn(wwn); in target_fabric_release_wwn() 937 struct se_wwn *wwn; in target_fabric_make_wwn() local [all …]
|
D | target_core_pscsi.c | 180 pscsi_set_inquiry_info(struct scsi_device *sdev, struct t10_wwn *wwn) in pscsi_set_inquiry_info() argument 193 memcpy(&wwn->vendor[0], &buf[8], sizeof(wwn->vendor)); in pscsi_set_inquiry_info() 194 memcpy(&wwn->model[0], &buf[16], sizeof(wwn->model)); in pscsi_set_inquiry_info() 195 memcpy(&wwn->revision[0], &buf[32], sizeof(wwn->revision)); in pscsi_set_inquiry_info() 199 pscsi_get_inquiry_vpd_serial(struct scsi_device *sdev, struct t10_wwn *wwn) in pscsi_get_inquiry_vpd_serial() argument 219 snprintf(&wwn->unit_serial[0], INQUIRY_VPD_SERIAL_LEN, "%s", &buf[4]); in pscsi_get_inquiry_vpd_serial() 221 wwn->t10_dev->dev_flags |= DF_FIRMWARE_VPD_UNIT_SERIAL; in pscsi_get_inquiry_vpd_serial() 233 struct t10_wwn *wwn) in pscsi_get_inquiry_vpd_device_ident() argument 291 list_add_tail(&vpd->vpd_list, &wwn->t10_vpd_list); in pscsi_get_inquiry_vpd_device_ident()
|
D | target_core_device.c | 722 struct t10_wwn *wwn = &dev->t10_wwn; in scsi_dump_inquiry() local 729 if (wwn->vendor[i] >= 0x20) in scsi_dump_inquiry() 730 buf[i] = wwn->vendor[i]; in scsi_dump_inquiry() 737 if (wwn->model[i] >= 0x20) in scsi_dump_inquiry() 738 buf[i] = wwn->model[i]; in scsi_dump_inquiry() 745 if (wwn->revision[i] >= 0x20) in scsi_dump_inquiry() 746 buf[i] = wwn->revision[i]; in scsi_dump_inquiry()
|
D | target_core_stat.c | 799 struct t10_wwn *wwn; in target_stat_transport_dev_name_show() local 805 wwn = &dev->t10_wwn; in target_stat_transport_dev_name_show() 809 (strlen(wwn->unit_serial)) ? wwn->unit_serial : in target_stat_transport_dev_name_show() 810 wwn->vendor); in target_stat_transport_dev_name_show()
|
/Linux-v4.19/drivers/scsi/qla2xxx/ |
D | tcm_qla2xxx.c | 58 static ssize_t tcm_qla2xxx_parse_wwn(const char *name, u64 *wwn, int strict) in tcm_qla2xxx_parse_wwn() argument 67 *wwn = 0; in tcm_qla2xxx_parse_wwn() 92 *wwn = (*wwn << 4) | nibble; in tcm_qla2xxx_parse_wwn() 101 static ssize_t tcm_qla2xxx_format_wwn(char *buf, size_t len, u64 wwn) in tcm_qla2xxx_format_wwn() argument 105 put_unaligned_be64(wwn, b); in tcm_qla2xxx_format_wwn() 122 u8 wwn[8]; in tcm_qla2xxx_npiv_extract_wwn() local 124 memset(wwn, 0, sizeof(wwn)); in tcm_qla2xxx_npiv_extract_wwn() 137 wwn[i/2] = j & 0xff; in tcm_qla2xxx_npiv_extract_wwn() 142 *nm = wwn_to_u64(wwn); in tcm_qla2xxx_npiv_extract_wwn() 1052 static struct se_portal_group *tcm_qla2xxx_make_tpg(struct se_wwn *wwn, in tcm_qla2xxx_make_tpg() argument [all …]
|
/Linux-v4.19/drivers/scsi/csiostor/ |
D | csio_attr.c | 561 uint8_t wwn[8]; in csio_vport_create() local 569 u64_to_wwn(fc_vport->node_name, wwn); in csio_vport_create() 571 if (!CSIO_VALID_WWN(wwn)) { in csio_vport_create() 576 memcpy(csio_ln_wwnn(ln), wwn, 8); in csio_vport_create() 580 u64_to_wwn(fc_vport->port_name, wwn); in csio_vport_create() 582 if (!CSIO_VALID_WWN(wwn)) { in csio_vport_create() 588 if (csio_lnode_lookup_by_wwpn(hw, wwn)) { in csio_vport_create() 593 memcpy(csio_ln_wwpn(ln), wwn, 8); in csio_vport_create()
|
/Linux-v4.19/drivers/scsi/bfa/ |
D | bfa_cs.h | 296 wwn2str(char *wwn_str, u64 wwn) in wwn2str() argument 299 u64 wwn; in wwn2str() member 303 w.wwn = wwn; in wwn2str()
|
D | bfa_fcbuild.h | 271 u16 fc_gmal_req_build(struct fchs_s *fchs, void *pyld, u32 s_id, wwn_t wwn); 272 u16 fc_gfn_req_build(struct fchs_s *fchs, void *pyld, u32 s_id, wwn_t wwn);
|
D | bfa_fcbuild.c | 1430 fc_gmal_req_build(struct fchs_s *fchs, void *pyld, u32 s_id, wwn_t wwn) in fc_gmal_req_build() argument 1441 gmal->wwn = wwn; in fc_gmal_req_build() 1450 fc_gfn_req_build(struct fchs_s *fchs, void *pyld, u32 s_id, wwn_t wwn) in fc_gfn_req_build() argument 1461 gfn->wwn = wwn; in fc_gfn_req_build()
|
/Linux-v4.19/drivers/target/loopback/ |
D | tcm_loop.c | 983 static struct se_portal_group *tcm_loop_make_naa_tpg(struct se_wwn *wwn, in tcm_loop_make_naa_tpg() argument 986 struct tcm_loop_hba *tl_hba = container_of(wwn, in tcm_loop_make_naa_tpg() 1010 ret = core_tpg_register(wwn, &tl_tpg->tl_se_tpg, tl_hba->tl_proto_id); in tcm_loop_make_naa_tpg() 1016 config_item_name(&wwn->wwn_group.cg_item), tpgt); in tcm_loop_make_naa_tpg() 1023 struct se_wwn *wwn = se_tpg->se_tpg_wwn; in tcm_loop_drop_naa_tpg() local 1045 config_item_name(&wwn->wwn_group.cg_item), tpgt); in tcm_loop_drop_naa_tpg() 1119 struct se_wwn *wwn) in tcm_loop_drop_scsi_hba() argument 1121 struct tcm_loop_hba *tl_hba = container_of(wwn, in tcm_loop_drop_scsi_hba()
|
/Linux-v4.19/include/scsi/ |
D | scsi_transport_fc.h | 758 static inline u64 wwn_to_u64(u8 *wwn) in wwn_to_u64() argument 760 return get_unaligned_be64(wwn); in wwn_to_u64() 763 static inline void u64_to_wwn(u64 inm, u8 *wwn) in u64_to_wwn() argument 765 put_unaligned_be64(inm, wwn); in u64_to_wwn()
|
D | libfcoe.h | 268 int fcoe_get_wwn(struct net_device *netdev, u64 *wwn, int type); 271 void fcoe_wwn_to_str(u64 wwn, char *buf, int len);
|
/Linux-v4.19/drivers/target/sbp/ |
D | sbp_target.c | 1935 static ssize_t sbp_parse_wwn(const char *name, u64 *wwn) in sbp_parse_wwn() argument 1941 *wwn = 0; in sbp_parse_wwn() 1959 *wwn = (*wwn << 4) | nibble; in sbp_parse_wwn() 1969 static ssize_t sbp_format_wwn(char *buf, size_t len, u64 wwn) in sbp_format_wwn() argument 1971 return snprintf(buf, len, "%016llx", wwn); in sbp_format_wwn() 2008 static struct se_portal_group *sbp_make_tpg(struct se_wwn *wwn, in sbp_make_tpg() argument 2012 container_of(wwn, struct sbp_tport, tport_wwn); in sbp_make_tpg() 2049 ret = core_tpg_register(wwn, &tpg->se_tpg, SCSI_PROTOCOL_SBP); in sbp_make_tpg() 2095 static void sbp_drop_tport(struct se_wwn *wwn) in sbp_drop_tport() argument 2098 container_of(wwn, struct sbp_tport, tport_wwn); in sbp_drop_tport()
|
/Linux-v4.19/drivers/target/iscsi/ |
D | iscsi_target_configfs.c | 1093 static struct se_portal_group *lio_target_tiqn_addtpg(struct se_wwn *wwn, in lio_target_tiqn_addtpg() argument 1102 tiqn = container_of(wwn, struct iscsi_tiqn, tiqn_wwn); in lio_target_tiqn_addtpg() 1122 ret = core_tpg_register(wwn, &tpg->tpg_se_tpg, SCSI_PROTOCOL_ISCSI); in lio_target_tiqn_addtpg() 1189 static void lio_target_add_wwn_groups(struct se_wwn *wwn) in lio_target_add_wwn_groups() argument 1191 struct iscsi_tiqn *tiqn = container_of(wwn, struct iscsi_tiqn, tiqn_wwn); in lio_target_add_wwn_groups() 1220 struct se_wwn *wwn) in lio_target_call_coredeltiqn() argument 1222 struct iscsi_tiqn *tiqn = container_of(wwn, struct iscsi_tiqn, tiqn_wwn); in lio_target_call_coredeltiqn()
|
/Linux-v4.19/drivers/scsi/fcoe/ |
D | fcoe_transport.c | 240 void fcoe_wwn_to_str(u64 wwn, char *buf, int len) in fcoe_wwn_to_str() argument 244 u64_to_wwn(wwn, wwpn); in fcoe_wwn_to_str() 302 int fcoe_get_wwn(struct net_device *netdev, u64 *wwn, int type) in fcoe_get_wwn() argument 307 return ops->ndo_fcoe_get_wwn(netdev, wwn, type); in fcoe_get_wwn()
|
D | fcoe_ctlr.c | 903 struct fip_wwn_desc *wwn; in fcoe_ctlr_parse_adv() local 964 wwn = (struct fip_wwn_desc *)desc; in fcoe_ctlr_parse_adv() 965 fcf->switch_name = get_unaligned_be64(&wwn->fd_wwn); in fcoe_ctlr_parse_adv() 1981 u64 wwn; in fcoe_wwn_from_mac() local 1993 wwn = host_mac | ((u64) scheme << 60); in fcoe_wwn_from_mac() 2000 wwn |= (u64) port << 48; in fcoe_wwn_from_mac() 2007 return wwn; in fcoe_wwn_from_mac() 2286 struct fip_wwn_desc *wwn = NULL; in fcoe_ctlr_vn_parse() local 2360 wwn = (struct fip_wwn_desc *)desc; in fcoe_ctlr_vn_parse() 2361 rdata->ids.node_name = get_unaligned_be64(&wwn->fd_wwn); in fcoe_ctlr_vn_parse() [all …]
|
/Linux-v4.19/drivers/infiniband/ulp/srpt/ |
D | ib_srpt.c | 2894 struct se_wwn *wwn; in srpt_lookup_wwn() local 2897 wwn = __srpt_lookup_wwn(name); in srpt_lookup_wwn() 2900 return wwn; in srpt_lookup_wwn() 3614 static struct se_portal_group *srpt_make_tpg(struct se_wwn *wwn, in srpt_make_tpg() argument 3617 struct srpt_port *sport = wwn->priv; in srpt_make_tpg() 3621 WARN_ON_ONCE(wwn != &sport->port_guid_wwn && in srpt_make_tpg() 3622 wwn != &sport->port_gid_wwn); in srpt_make_tpg() 3623 tpg = wwn == &sport->port_guid_wwn ? &sport->port_guid_tpg : in srpt_make_tpg() 3625 res = core_tpg_register(wwn, tpg, SCSI_PROTOCOL_SRP); in srpt_make_tpg() 3661 static void srpt_drop_tport(struct se_wwn *wwn) in srpt_drop_tport() argument
|
/Linux-v4.19/drivers/xen/ |
D | xen-scsiback.c | 1368 static void scsiback_drop_tport(struct se_wwn *wwn) in scsiback_drop_tport() argument 1370 struct scsiback_tport *tport = container_of(wwn, in scsiback_drop_tport() 1745 scsiback_make_tpg(struct se_wwn *wwn, const char *name) in scsiback_make_tpg() argument 1747 struct scsiback_tport *tport = container_of(wwn, in scsiback_make_tpg() 1770 ret = core_tpg_register(wwn, &tpg->se_tpg, tport->tport_proto_id); in scsiback_make_tpg()
|