diff --git a/drivers/dax/pmem.c b/drivers/dax/pmem.c index dfb168568af1a6d2ba163a7010d611ec0ad3a3f0..1f01e98c83c7ddcccecd50e11671e3b519b2c136 100644 --- a/drivers/dax/pmem.c +++ b/drivers/dax/pmem.c @@ -116,6 +116,9 @@ static int dax_pmem_probe(struct device *dev) if (rc) return rc; + /* adjust the dax_region resource to the start of data */ + res.start += le64_to_cpu(pfn_sb->dataoff); + nd_region = to_nd_region(dev->parent); dax_region = alloc_dax_region(dev, nd_region->id, &res, le32_to_cpu(pfn_sb->align), addr, PFN_DEV|PFN_MAP);