diff options
Diffstat (limited to 'drivers/dax/pmem.c')
-rw-r--r-- | drivers/dax/pmem.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/dax/pmem.c b/drivers/dax/pmem.c index c24d32ec9ce6..9630d8837ba9 100644 --- a/drivers/dax/pmem.c +++ b/drivers/dax/pmem.c @@ -117,6 +117,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); |