powerpc/pmem: Initialize pmem device on newer hardware
authorAneesh Kumar K.V <aneesh.kumar@linux.ibm.com>
Wed, 1 Jul 2020 07:22:35 +0000 (12:52 +0530)
committerMichael Ellerman <mpe@ellerman.id.au>
Thu, 16 Jul 2020 03:00:23 +0000 (13:00 +1000)
With kernel now supporting new pmem flush/sync instructions, we can now
enable the kernel to initialize the device. On P10 these devices would
appear with a new compatible string. For PAPR device we have

compatible       "ibm,pmemory-v2"

and for OF pmem device we have

compatible       "pmem-region-v2"

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20200701072235.223558-8-aneesh.kumar@linux.ibm.com
arch/powerpc/platforms/pseries/papr_scm.c
drivers/nvdimm/of_pmem.c

index 9c569078a09fd3c8564e46c0af6d5f4a798c222b..66c19c0fe5667b6118cccf8cb3e03f46b87d7199 100644 (file)
@@ -876,6 +876,7 @@ static int papr_scm_remove(struct platform_device *pdev)
 
 static const struct of_device_id papr_scm_match[] = {
        { .compatible = "ibm,pmemory" },
+       { .compatible = "ibm,pmemory-v2" },
        { },
 };
 
index 6826a274a1f105b9520947d154d7b16f86e0914a..10dbdcdfb9ce9137b79896d61568596cf14b03d5 100644 (file)
@@ -90,6 +90,7 @@ static int of_pmem_region_remove(struct platform_device *pdev)
 
 static const struct of_device_id of_pmem_region_match[] = {
        { .compatible = "pmem-region" },
+       { .compatible = "pmem-region-v2" },
        { },
 };