Lines Matching refs:subsys

313 	struct nvmet_subsys *subsys = ns->subsys;  in nvmet_ns_device_path_store()  local
317 mutex_lock(&subsys->lock); in nvmet_ns_device_path_store()
333 mutex_unlock(&subsys->lock); in nvmet_ns_device_path_store()
337 mutex_unlock(&subsys->lock); in nvmet_ns_device_path_store()
352 struct nvmet_subsys *subsys = ns->subsys; in nvmet_ns_device_uuid_store() local
356 mutex_lock(&subsys->lock); in nvmet_ns_device_uuid_store()
367 mutex_unlock(&subsys->lock); in nvmet_ns_device_uuid_store()
382 struct nvmet_subsys *subsys = ns->subsys; in nvmet_ns_device_nguid_store() local
388 mutex_lock(&subsys->lock); in nvmet_ns_device_nguid_store()
413 mutex_unlock(&subsys->lock); in nvmet_ns_device_nguid_store()
446 nvmet_send_ana_event(ns->subsys, NULL); in nvmet_ns_ana_grpid_store()
491 mutex_lock(&ns->subsys->lock); in nvmet_ns_buffered_io_store()
494 mutex_unlock(&ns->subsys->lock); in nvmet_ns_buffered_io_store()
499 mutex_unlock(&ns->subsys->lock); in nvmet_ns_buffered_io_store()
535 struct nvmet_subsys *subsys = namespaces_to_subsys(&group->cg_item); in nvmet_ns_make() local
549 ns = nvmet_ns_alloc(subsys, nsid); in nvmet_ns_make()
554 pr_info("adding nsid %d to subsystem %s\n", nsid, subsys->subsysnqn); in nvmet_ns_make()
574 struct nvmet_subsys *subsys; in nvmet_port_subsys_allow_link() local
582 subsys = to_subsys(target); in nvmet_port_subsys_allow_link()
586 link->subsys = subsys; in nvmet_port_subsys_allow_link()
591 if (p->subsys == subsys) in nvmet_port_subsys_allow_link()
616 struct nvmet_subsys *subsys = to_subsys(target); in nvmet_port_subsys_drop_link() local
621 if (p->subsys == subsys) in nvmet_port_subsys_drop_link()
649 struct nvmet_subsys *subsys = to_subsys(parent->ci_parent); in nvmet_allowed_hosts_allow_link() local
667 if (subsys->allow_any_host) { in nvmet_allowed_hosts_allow_link()
673 list_for_each_entry(p, &subsys->hosts, entry) { in nvmet_allowed_hosts_allow_link()
677 list_add_tail(&link->entry, &subsys->hosts); in nvmet_allowed_hosts_allow_link()
690 struct nvmet_subsys *subsys = to_subsys(parent->ci_parent); in nvmet_allowed_hosts_drop_link() local
695 list_for_each_entry(p, &subsys->hosts, entry) { in nvmet_allowed_hosts_drop_link()
729 struct nvmet_subsys *subsys = to_subsys(item); in nvmet_subsys_attr_allow_any_host_store() local
737 if (allow_any_host && !list_empty(&subsys->hosts)) { in nvmet_subsys_attr_allow_any_host_store()
743 subsys->allow_any_host = allow_any_host; in nvmet_subsys_attr_allow_any_host_store()
754 struct nvmet_subsys *subsys = to_subsys(item); in nvmet_subsys_attr_version_show() local
756 if (NVME_TERTIARY(subsys->ver)) in nvmet_subsys_attr_version_show()
758 (int)NVME_MAJOR(subsys->ver), in nvmet_subsys_attr_version_show()
759 (int)NVME_MINOR(subsys->ver), in nvmet_subsys_attr_version_show()
760 (int)NVME_TERTIARY(subsys->ver)); in nvmet_subsys_attr_version_show()
763 (int)NVME_MAJOR(subsys->ver), in nvmet_subsys_attr_version_show()
764 (int)NVME_MINOR(subsys->ver)); in nvmet_subsys_attr_version_show()
770 struct nvmet_subsys *subsys = to_subsys(item); in nvmet_subsys_attr_version_store() local
780 subsys->ver = NVME_VS(major, minor, tertiary); in nvmet_subsys_attr_version_store()
790 struct nvmet_subsys *subsys = to_subsys(item); in nvmet_subsys_attr_serial_show() local
792 return snprintf(page, PAGE_SIZE, "%llx\n", subsys->serial); in nvmet_subsys_attr_serial_show()
798 struct nvmet_subsys *subsys = to_subsys(item); in nvmet_subsys_attr_serial_store() local
801 sscanf(page, "%llx\n", &subsys->serial); in nvmet_subsys_attr_serial_store()
820 struct nvmet_subsys *subsys = to_subsys(item); in nvmet_subsys_release() local
822 nvmet_subsys_del_ctrls(subsys); in nvmet_subsys_release()
823 nvmet_subsys_put(subsys); in nvmet_subsys_release()
839 struct nvmet_subsys *subsys; in nvmet_subsys_make() local
846 subsys = nvmet_subsys_alloc(name, NVME_NQN_NVME); in nvmet_subsys_make()
847 if (!subsys) in nvmet_subsys_make()
850 config_group_init_type_name(&subsys->group, name, &nvmet_subsys_type); in nvmet_subsys_make()
852 config_group_init_type_name(&subsys->namespaces_group, in nvmet_subsys_make()
854 configfs_add_default_group(&subsys->namespaces_group, &subsys->group); in nvmet_subsys_make()
856 config_group_init_type_name(&subsys->allowed_hosts_group, in nvmet_subsys_make()
858 configfs_add_default_group(&subsys->allowed_hosts_group, in nvmet_subsys_make()
859 &subsys->group); in nvmet_subsys_make()
861 return &subsys->group; in nvmet_subsys_make()