Lines Matching refs:lun
66 struct se_lun *lun = container_of(to_config_group(lun_ci), in target_fabric_mappedlun_link() local
74 if (lun->lun_link_magic != SE_LUN_LINK_MAGIC) { in target_fabric_mappedlun_link()
76 " %p to struct lun: %p\n", lun_ci, lun); in target_fabric_mappedlun_link()
82 if (!lun->lun_sep || !lun->lun_sep->sep_tpg) { in target_fabric_mappedlun_link()
87 if (lun->lun_shutdown) { in target_fabric_mappedlun_link()
92 se_tpg = lun->lun_sep->sep_tpg; in target_fabric_mappedlun_link()
136 lun->unpacked_lun, lun_access); in target_fabric_mappedlun_link()
145 struct se_lun *lun; in target_fabric_mappedlun_unlink() local
157 lun = container_of(to_config_group(lun_ci), struct se_lun, lun_group); in target_fabric_mappedlun_unlink()
158 se_tpg = lun->lun_sep->sep_tpg; in target_fabric_mappedlun_unlink()
160 core_dev_del_initiator_node_lun_acl(se_tpg, lun, lacl); in target_fabric_mappedlun_unlink()
645 struct se_lun *lun, in target_fabric_port_show_attr_alua_tg_pt_gp() argument
648 if (!lun || !lun->lun_sep) in target_fabric_port_show_attr_alua_tg_pt_gp()
651 return core_alua_show_tg_pt_gp_info(lun->lun_sep, page); in target_fabric_port_show_attr_alua_tg_pt_gp()
655 struct se_lun *lun, in target_fabric_port_store_attr_alua_tg_pt_gp() argument
659 if (!lun || !lun->lun_sep) in target_fabric_port_store_attr_alua_tg_pt_gp()
662 return core_alua_store_tg_pt_gp_info(lun->lun_sep, page, count); in target_fabric_port_store_attr_alua_tg_pt_gp()
671 struct se_lun *lun, in target_fabric_port_show_attr_alua_tg_pt_offline() argument
674 if (!lun || !lun->lun_sep) in target_fabric_port_show_attr_alua_tg_pt_offline()
677 return core_alua_show_offline_bit(lun, page); in target_fabric_port_show_attr_alua_tg_pt_offline()
681 struct se_lun *lun, in target_fabric_port_store_attr_alua_tg_pt_offline() argument
685 if (!lun || !lun->lun_sep) in target_fabric_port_store_attr_alua_tg_pt_offline()
688 return core_alua_store_offline_bit(lun, page, count); in target_fabric_port_store_attr_alua_tg_pt_offline()
697 struct se_lun *lun, in target_fabric_port_show_attr_alua_tg_pt_status() argument
700 if (!lun || !lun->lun_sep) in target_fabric_port_show_attr_alua_tg_pt_status()
703 return core_alua_show_secondary_status(lun, page); in target_fabric_port_show_attr_alua_tg_pt_status()
707 struct se_lun *lun, in target_fabric_port_store_attr_alua_tg_pt_status() argument
711 if (!lun || !lun->lun_sep) in target_fabric_port_store_attr_alua_tg_pt_status()
714 return core_alua_store_secondary_status(lun, page, count); in target_fabric_port_store_attr_alua_tg_pt_status()
723 struct se_lun *lun, in target_fabric_port_show_attr_alua_tg_pt_write_md() argument
726 if (!lun || !lun->lun_sep) in target_fabric_port_show_attr_alua_tg_pt_write_md()
729 return core_alua_show_secondary_write_metadata(lun, page); in target_fabric_port_show_attr_alua_tg_pt_write_md()
733 struct se_lun *lun, in target_fabric_port_store_attr_alua_tg_pt_write_md() argument
737 if (!lun || !lun->lun_sep) in target_fabric_port_store_attr_alua_tg_pt_write_md()
740 return core_alua_store_secondary_write_metadata(lun, page, count); in target_fabric_port_store_attr_alua_tg_pt_write_md()
761 struct se_lun *lun = container_of(to_config_group(lun_ci), in target_fabric_port_link() local
786 if (lun->lun_se_dev != NULL) { in target_fabric_port_link()
791 lun_p = core_dev_add_lun(se_tpg, dev, lun->unpacked_lun); in target_fabric_port_link()
804 tf->tf_ops.fabric_post_link(se_tpg, lun); in target_fabric_port_link()
816 struct se_lun *lun = container_of(to_config_group(lun_ci), in target_fabric_port_unlink() local
818 struct se_portal_group *se_tpg = lun->lun_sep->sep_tpg; in target_fabric_port_unlink()
827 tf->tf_ops.fabric_pre_unlink(se_tpg, lun); in target_fabric_port_unlink()
830 core_dev_del_lun(se_tpg, lun); in target_fabric_port_unlink()
876 struct se_lun *lun; in target_fabric_make_lun() local
895 lun = core_get_lun_from_tpg(se_tpg, unpacked_lun); in target_fabric_make_lun()
896 if (!lun) in target_fabric_make_lun()
899 lun_cg = &lun->lun_group; in target_fabric_make_lun()
907 config_group_init_type_name(&lun->lun_group, name, in target_fabric_make_lun()
909 config_group_init_type_name(&lun->port_stat_grps.stat_group, in target_fabric_make_lun()
911 lun_cg->default_groups[0] = &lun->port_stat_grps.stat_group; in target_fabric_make_lun()
914 port_stat_grp = &lun->port_stat_grps.stat_group; in target_fabric_make_lun()
922 target_stat_setup_port_default_groups(lun); in target_fabric_make_lun()
924 return &lun->lun_group; in target_fabric_make_lun()
931 struct se_lun *lun = container_of(to_config_group(item), in target_fabric_drop_lun() local
937 port_stat_grp = &lun->port_stat_grps.stat_group; in target_fabric_drop_lun()
945 lun_cg = &lun->lun_group; in target_fabric_drop_lun()