Lines Matching defs:ndns

24 	nd_detach_ndns(&nd_pfn->dev, &nd_pfn->ndns);
174 rc = sprintf(buf, "%s\n", nd_pfn->ndns
175 ? dev_name(&nd_pfn->ndns->dev) : "");
188 rc = nd_namespace_store(dev, &nd_pfn->ndns, buf, len);
208 struct nd_namespace_common *ndns = nd_pfn->ndns;
210 struct nd_namespace_io *nsio = to_nd_namespace_io(&ndns->dev);
234 struct nd_namespace_common *ndns = nd_pfn->ndns;
237 struct nd_namespace_io *nsio = to_nd_namespace_io(&ndns->dev);
299 struct nd_namespace_common *ndns)
311 if (ndns && !__nd_attach_ndns(&nd_pfn->dev, ndns, &nd_pfn->ndns)) {
312 dev_dbg(&ndns->dev, "failed, already claimed by %s\n",
313 dev_name(ndns->claim));
367 struct nd_namespace_common *ndns = nd_pfn->ndns;
377 nsio = to_nd_namespace_io(&ndns->dev);
385 devm_namespace_disable(&nd_pfn->dev, ndns);
386 rc = devm_namespace_enable(&nd_pfn->dev, ndns, le64_to_cpu(pfn_sb->dataoff));
406 rc = nvdimm_write_bytes(ndns, nsoff, zero_page,
459 struct nd_namespace_common *ndns = nd_pfn->ndns;
460 const uuid_t *parent_uuid = nd_dev_to_uuid(&ndns->dev);
462 if (!pfn_sb || !ndns)
468 if (nvdimm_read_bytes(ndns, SZ_4K, pfn_sb, sizeof(*pfn_sb), 0))
575 if (align > nvdimm_namespace_capacity(ndns)) {
577 align, nvdimm_namespace_capacity(ndns));
587 nsio = to_nd_namespace_io(&ndns->dev);
592 dev_name(&ndns->dev));
622 int nd_pfn_probe(struct device *dev, struct nd_namespace_common *ndns)
628 struct nd_region *nd_region = to_nd_region(ndns->dev.parent);
630 if (ndns->force_raw)
633 switch (ndns->claim_class) {
641 nvdimm_bus_lock(&ndns->dev);
643 pfn_dev = nd_pfn_devinit(nd_pfn, ndns);
644 nvdimm_bus_unlock(&ndns->dev);
653 nd_detach_ndns(pfn_dev, &nd_pfn->ndns);
691 struct nd_namespace_common *ndns = nd_pfn->ndns;
692 struct nd_namespace_io *nsio = to_nd_namespace_io(&ndns->dev);
729 struct nd_namespace_common *ndns = nd_pfn->ndns;
730 struct nd_namespace_io *nsio = to_nd_namespace_io(&ndns->dev);
780 dev_name(&ndns->dev), &start,
821 dev_name(&ndns->dev));
831 memcpy(pfn_sb->parent_uuid, nd_dev_to_uuid(&ndns->dev), 16);
848 return nvdimm_write_bytes(ndns, SZ_4K, pfn_sb, sizeof(*pfn_sb), 0);
859 if (!nd_pfn->uuid || !nd_pfn->ndns)