• Home
  • Raw
  • Download

Lines Matching refs:tl_hba

115 	struct tcm_loop_hba *tl_hba;  in tcm_loop_submission_work()  local
121 tl_hba = *(struct tcm_loop_hba **)shost_priv(sc->device->host); in tcm_loop_submission_work()
122 tl_tpg = &tl_hba->tl_hba_tpgs[sc->device->id]; in tcm_loop_submission_work()
128 if (!tl_tpg->tl_hba) { in tcm_loop_submission_work()
296 struct tcm_loop_hba *tl_hba; in tcm_loop_abort_task() local
303 tl_hba = *(struct tcm_loop_hba **)shost_priv(sc->device->host); in tcm_loop_abort_task()
304 tl_tpg = &tl_hba->tl_hba_tpgs[sc->device->id]; in tcm_loop_abort_task()
316 struct tcm_loop_hba *tl_hba; in tcm_loop_device_reset() local
323 tl_hba = *(struct tcm_loop_hba **)shost_priv(sc->device->host); in tcm_loop_device_reset()
324 tl_tpg = &tl_hba->tl_hba_tpgs[sc->device->id]; in tcm_loop_device_reset()
333 struct tcm_loop_hba *tl_hba; in tcm_loop_target_reset() local
339 tl_hba = *(struct tcm_loop_hba **)shost_priv(sc->device->host); in tcm_loop_target_reset()
340 if (!tl_hba) { in tcm_loop_target_reset()
348 tl_tpg = &tl_hba->tl_hba_tpgs[sc->device->id]; in tcm_loop_target_reset()
384 struct tcm_loop_hba *tl_hba; in tcm_loop_driver_probe() local
388 tl_hba = to_tcm_loop_hba(dev); in tcm_loop_driver_probe()
396 tl_hba->sh = sh; in tcm_loop_driver_probe()
401 *((struct tcm_loop_hba **)sh->hostdata) = tl_hba; in tcm_loop_driver_probe()
417 error = scsi_add_host(sh, &tl_hba->dev); in tcm_loop_driver_probe()
428 struct tcm_loop_hba *tl_hba; in tcm_loop_driver_remove() local
431 tl_hba = to_tcm_loop_hba(dev); in tcm_loop_driver_remove()
432 sh = tl_hba->sh; in tcm_loop_driver_remove()
441 struct tcm_loop_hba *tl_hba = to_tcm_loop_hba(dev); in tcm_loop_release_adapter() local
443 kfree(tl_hba); in tcm_loop_release_adapter()
449 static int tcm_loop_setup_hba_bus(struct tcm_loop_hba *tl_hba, int tcm_loop_host_id) in tcm_loop_setup_hba_bus() argument
453 tl_hba->dev.bus = &tcm_loop_lld_bus; in tcm_loop_setup_hba_bus()
454 tl_hba->dev.parent = tcm_loop_primary; in tcm_loop_setup_hba_bus()
455 tl_hba->dev.release = &tcm_loop_release_adapter; in tcm_loop_setup_hba_bus()
456 dev_set_name(&tl_hba->dev, "tcm_loop_adapter_%d", tcm_loop_host_id); in tcm_loop_setup_hba_bus()
458 ret = device_register(&tl_hba->dev); in tcm_loop_setup_hba_bus()
529 return &tl_tpg(se_tpg)->tl_hba->tl_wwn_address[0]; in tcm_loop_get_endpoint_wwn()
697 static char *tcm_loop_dump_proto_id(struct tcm_loop_hba *tl_hba) in tcm_loop_dump_proto_id() argument
699 switch (tl_hba->tl_proto_id) { in tcm_loop_dump_proto_id()
721 struct tcm_loop_hba *tl_hba = tl_tpg->tl_hba; in tcm_loop_port_link() local
727 scsi_add_device(tl_hba->sh, 0, tl_tpg->tl_tpgt, lun->unpacked_lun); in tcm_loop_port_link()
738 struct tcm_loop_hba *tl_hba; in tcm_loop_port_unlink() local
742 tl_hba = tl_tpg->tl_hba; in tcm_loop_port_unlink()
744 sd = scsi_device_lookup(tl_hba->sh, 0, tl_tpg->tl_tpgt, in tcm_loop_port_unlink()
810 struct tcm_loop_hba *tl_hba = tl_tpg->tl_hba; in tcm_loop_make_nexus() local
850 " %s Initiator Port: %s\n", tcm_loop_dump_proto_id(tl_hba), in tcm_loop_make_nexus()
881 " %s Initiator Port: %s\n", tcm_loop_dump_proto_id(tpg->tl_hba), in tcm_loop_drop_nexus()
918 struct tcm_loop_hba *tl_hba = tl_tpg->tl_hba; in tcm_loop_tpg_nexus_store() local
942 if (tl_hba->tl_proto_id != SCSI_PROTOCOL_SAS) { in tcm_loop_tpg_nexus_store()
945 tcm_loop_dump_proto_id(tl_hba)); in tcm_loop_tpg_nexus_store()
953 if (tl_hba->tl_proto_id != SCSI_PROTOCOL_FCP) { in tcm_loop_tpg_nexus_store()
956 tcm_loop_dump_proto_id(tl_hba)); in tcm_loop_tpg_nexus_store()
964 if (tl_hba->tl_proto_id != SCSI_PROTOCOL_ISCSI) { in tcm_loop_tpg_nexus_store()
967 tcm_loop_dump_proto_id(tl_hba)); in tcm_loop_tpg_nexus_store()
1055 struct tcm_loop_hba *tl_hba = container_of(wwn, in tcm_loop_make_naa_tpg() local
1074 tl_tpg = &tl_hba->tl_hba_tpgs[tpgt]; in tcm_loop_make_naa_tpg()
1075 tl_tpg->tl_hba = tl_hba; in tcm_loop_make_naa_tpg()
1080 ret = core_tpg_register(wwn, &tl_tpg->tl_se_tpg, tl_hba->tl_proto_id); in tcm_loop_make_naa_tpg()
1085 " Target Port %s,t,0x%04lx\n", tcm_loop_dump_proto_id(tl_hba), in tcm_loop_make_naa_tpg()
1097 struct tcm_loop_hba *tl_hba; in tcm_loop_drop_naa_tpg() local
1100 tl_hba = tl_tpg->tl_hba; in tcm_loop_drop_naa_tpg()
1111 tl_tpg->tl_hba = NULL; in tcm_loop_drop_naa_tpg()
1115 " Target Port %s,t,0x%04x\n", tcm_loop_dump_proto_id(tl_hba), in tcm_loop_drop_naa_tpg()
1128 struct tcm_loop_hba *tl_hba; in tcm_loop_make_scsi_hba() local
1133 tl_hba = kzalloc(sizeof(struct tcm_loop_hba), GFP_KERNEL); in tcm_loop_make_scsi_hba()
1134 if (!tl_hba) { in tcm_loop_make_scsi_hba()
1144 tl_hba->tl_proto_id = SCSI_PROTOCOL_SAS; in tcm_loop_make_scsi_hba()
1149 tl_hba->tl_proto_id = SCSI_PROTOCOL_FCP; in tcm_loop_make_scsi_hba()
1160 tl_hba->tl_proto_id = SCSI_PROTOCOL_ISCSI; in tcm_loop_make_scsi_hba()
1165 " max: %d\n", name, tcm_loop_dump_proto_id(tl_hba), in tcm_loop_make_scsi_hba()
1170 snprintf(&tl_hba->tl_wwn_address[0], TL_WWN_ADDR_LEN, "%s", &name[off]); in tcm_loop_make_scsi_hba()
1177 ret = tcm_loop_setup_hba_bus(tl_hba, tcm_loop_hba_no_cnt); in tcm_loop_make_scsi_hba()
1181 sh = tl_hba->sh; in tcm_loop_make_scsi_hba()
1185 tcm_loop_dump_proto_id(tl_hba), name, sh->host_no); in tcm_loop_make_scsi_hba()
1187 return &tl_hba->tl_hba_wwn; in tcm_loop_make_scsi_hba()
1189 kfree(tl_hba); in tcm_loop_make_scsi_hba()
1196 struct tcm_loop_hba *tl_hba = container_of(wwn, in tcm_loop_drop_scsi_hba() local
1201 tcm_loop_dump_proto_id(tl_hba), tl_hba->tl_wwn_address, in tcm_loop_drop_scsi_hba()
1202 tl_hba->sh->host_no); in tcm_loop_drop_scsi_hba()
1208 device_unregister(&tl_hba->dev); in tcm_loop_drop_scsi_hba()