libnvdimm, pfn: fix restoring memmap location
authorDan Williams <dan.j.williams@intel.com>
Sat, 30 Jan 2016 01:42:51 +0000 (17:42 -0800)
committerDan Williams <dan.j.williams@intel.com>
Sat, 30 Jan 2016 01:43:16 +0000 (17:43 -0800)
This path was missed when turning on the memmap in pmem support.  Permit
'pmem' as a valid location for the map.

Reported-by: Jeff Moyer <jmoyer@redhat.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
drivers/nvdimm/pfn_devs.c

index 0cc9048b86e23103900d36f75a0b64746521ee18..ae81a2f1da50b1e9f9cf5a14bd180df19b3ccab1 100644 (file)
@@ -301,10 +301,8 @@ int nd_pfn_validate(struct nd_pfn *nd_pfn)
 
        switch (le32_to_cpu(pfn_sb->mode)) {
        case PFN_MODE_RAM:
-               break;
        case PFN_MODE_PMEM:
-               /* TODO: allocate from PMEM support */
-               return -ENOTTY;
+               break;
        default:
                return -ENXIO;
        }