mfd: Enable Device Tree support in the ab8500-sysctrl driver
authorLee Jones <lee.jones@linaro.org>
Fri, 18 May 2012 08:39:10 +0000 (09:39 +0100)
committerSamuel Ortiz <sameo@linux.intel.com>
Sun, 20 May 2012 15:27:13 +0000 (17:27 +0200)
This patch ensures probing of the ab8500-sysctrl driver during a DT
enabled boot, so long as the associated nodes are present in the
Device Tree binary.

Signed-off-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
drivers/mfd/ab8500-sysctrl.c

index c28d4eb1eff019517d166476c590652f2ac1b8b1..5a3e51ccf25863b94dccd26b25f4e7002b90ac97 100644 (file)
@@ -61,10 +61,16 @@ static int __devexit ab8500_sysctrl_remove(struct platform_device *pdev)
        return 0;
 }
 
+static const struct of_device_id ab8500_sysctrl_match[] = {
+       { .compatible = "stericsson,ab8500-sysctrl", },
+       {}
+};
+
 static struct platform_driver ab8500_sysctrl_driver = {
        .driver = {
                .name = "ab8500-sysctrl",
                .owner = THIS_MODULE,
+               .of_match_table = ab8500_sysctrl_match,
        },
        .probe = ab8500_sysctrl_probe,
        .remove = __devexit_p(ab8500_sysctrl_remove),