Lines Matching refs:nd_region
705 static unsigned long dpa_align(struct nd_region *nd_region) in dpa_align() argument
707 struct device *dev = &nd_region->dev; in dpa_align()
712 if (dev_WARN_ONCE(dev, !nd_region->ndr_mappings || nd_region->align in dpa_align()
713 % nd_region->ndr_mappings, in dpa_align()
715 nd_region->align, nd_region->ndr_mappings)) in dpa_align()
717 return nd_region->align / nd_region->ndr_mappings; in dpa_align()
726 resource_size_t nd_pmem_max_contiguous_dpa(struct nd_region *nd_region, in nd_pmem_max_contiguous_dpa() argument
739 align = dpa_align(nd_region); in nd_pmem_max_contiguous_dpa()
744 if (__reserve_free_pmem(&nd_region->dev, nd_mapping->nvdimm)) in nd_pmem_max_contiguous_dpa()
771 resource_size_t nd_pmem_available_dpa(struct nd_region *nd_region, in nd_pmem_available_dpa() argument
782 align = dpa_align(nd_region); in nd_pmem_available_dpa()
795 nd_dbg_dpa(nd_region, ndd, res, in nd_pmem_available_dpa()