Lines Matching refs:label_id

299 	struct nd_label_id label_id;  in nd_namespace_blk_size()  local
305 nd_label_gen_id(&label_id, nsblk->uuid, NSLABEL_FLAG_LOCAL); in nd_namespace_blk_size()
307 if (strcmp(res->name, label_id.id) == 0) in nd_namespace_blk_size()
317 struct nd_label_id label_id; in __nd_namespace_blk_validate() local
325 nd_label_gen_id(&label_id, nsblk->uuid, NSLABEL_FLAG_LOCAL); in __nd_namespace_blk_validate()
327 if (strcmp(res->name, label_id.id) != 0) in __nd_namespace_blk_validate()
447 struct nd_mapping *nd_mapping, struct nd_label_id *label_id, in scan_free() argument
450 bool is_blk = strncmp(label_id->id, "blk", 3) == 0; in scan_free()
460 if (strcmp(res->name, label_id->id) == 0) in scan_free()
505 struct nd_label_id *label_id, resource_size_t n) in shrink_dpa_allocation() argument
513 rc = scan_free(nd_region, nd_mapping, label_id, n); in shrink_dpa_allocation()
521 static resource_size_t init_dpa_allocation(struct nd_label_id *label_id, in init_dpa_allocation() argument
525 bool is_blk = strncmp(label_id->id, "blk", 3) == 0; in init_dpa_allocation()
538 res = nvdimm_allocate_dpa(ndd, label_id, first_dpa, n); in init_dpa_allocation()
564 struct nd_label_id *label_id, struct resource *prev, in space_valid() argument
568 bool is_reserve = strcmp(label_id->id, "pmem-reserve") == 0; in space_valid()
569 bool is_pmem = strncmp(label_id->id, "pmem", 4) == 0; in space_valid()
615 struct nd_mapping *nd_mapping, struct nd_label_id *label_id, in scan_allocate() argument
619 bool is_pmem = strncmp(label_id->id, "pmem", 4) == 0; in scan_allocate()
626 if (strcmp(label_id->id, res->name) == 0) in scan_allocate()
651 space_valid(nd_region, ndd, label_id, NULL, next, exist, in scan_allocate()
662 space_valid(nd_region, ndd, label_id, res, next, exist, in scan_allocate()
673 space_valid(nd_region, ndd, label_id, res, next, exist, in scan_allocate()
685 if (strcmp(res->name, label_id->id) == 0) { in scan_allocate()
694 if (strcmp(next->name, label_id->id) == 0) { in scan_allocate()
701 } else if (strcmp(res->name, label_id->id) == 0) { in scan_allocate()
707 if (strcmp(res->name, label_id->id) == 0) in scan_allocate()
721 new_res = nvdimm_allocate_dpa(ndd, label_id, in scan_allocate()
762 return init_dpa_allocation(label_id, nd_region, nd_mapping, n); in scan_allocate()
767 struct nd_mapping *nd_mapping, struct nd_label_id *label_id) in merge_dpa() argument
772 if (strncmp("pmem", label_id->id, 4) == 0) in merge_dpa()
780 if (!next || strcmp(res->name, label_id->id) != 0 in merge_dpa()
781 || strcmp(next->name, label_id->id) != 0 in merge_dpa()
801 struct nd_label_id label_id; in __reserve_free_pmem() local
811 memset(&label_id, 0, sizeof(label_id)); in __reserve_free_pmem()
812 strcat(label_id.id, "pmem-reserve"); in __reserve_free_pmem()
823 rem = scan_allocate(nd_region, nd_mapping, &label_id, n); in __reserve_free_pmem()
872 struct nd_label_id *label_id, resource_size_t n) in grow_dpa_allocation() argument
875 bool is_pmem = strncmp(label_id->id, "pmem", 4) == 0; in grow_dpa_allocation()
896 label_id, rem); in grow_dpa_allocation()
912 rc = merge_dpa(nd_region, nd_mapping, label_id); in grow_dpa_allocation()
934 struct nd_label_id label_id; in nd_namespace_pmem_set_resource() local
942 nd_label_gen_id(&label_id, nspm->uuid, 0); in nd_namespace_pmem_set_resource()
946 if (strcmp(res->name, label_id.id) == 0) { in nd_namespace_pmem_set_resource()
977 struct nd_label_id label_id; in __size_store() local
1016 nd_label_gen_id(&label_id, uuid, flags); in __size_store()
1028 allocated += nvdimm_allocated_dpa(ndd, &label_id); in __size_store()
1041 rc = shrink_dpa_allocation(nd_region, &label_id, in __size_store()
1044 rc = grow_dpa_allocation(nd_region, &label_id, val - allocated); in __size_store()
1253 struct nd_label_id label_id; in namespace_update_uuid() local
1257 nd_label_gen_id(&label_id, nd_label->uuid, in namespace_update_uuid()
1259 if (strcmp(old_label_id.id, label_id.id) == 0) in namespace_update_uuid()
1400 struct nd_label_id label_id; in dpa_extents_show() local
1421 nd_label_gen_id(&label_id, uuid, flags); in dpa_extents_show()
1428 if (strcmp(res->name, label_id.id) == 0) in dpa_extents_show()
2041 struct nd_label_id label_id; in nsblk_add_resource() local
2044 nd_label_gen_id(&label_id, nsblk->uuid, NSLABEL_FLAG_LOCAL); in nsblk_add_resource()
2052 if (strcmp(res->name, label_id.id) == 0 in nsblk_add_resource()