]> git.karo-electronics.de Git - linux-beck.git/commitdiff
crypto: picoxcell - Use of_match_ptr() macro
authorSachin Kamat <sachin.kamat@linaro.org>
Thu, 14 Mar 2013 10:16:58 +0000 (15:46 +0530)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 22 Mar 2013 10:13:55 +0000 (18:13 +0800)
This eliminates having an #ifdef returning NULL for the case
when OF is disabled.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Acked-by: Jamie Iles <jamie@jamieiles.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/picoxcell_crypto.c

index 2096d4685a9e362a1837f58ee8b3477a4340a410..ac30724d923d4d0fef56fec1e7ad37dbec747402 100644 (file)
@@ -1688,8 +1688,6 @@ static const struct of_device_id spacc_of_id_table[] = {
        { .compatible = "picochip,spacc-l2" },
        {}
 };
-#else /* CONFIG_OF */
-#define spacc_of_id_table NULL
 #endif /* CONFIG_OF */
 
 static bool spacc_is_compatible(struct platform_device *pdev,
@@ -1874,7 +1872,7 @@ static struct platform_driver spacc_driver = {
 #ifdef CONFIG_PM
                .pm     = &spacc_pm_ops,
 #endif /* CONFIG_PM */
-               .of_match_table = spacc_of_id_table,
+               .of_match_table = of_match_ptr(spacc_of_id_table),
        },
        .id_table       = spacc_id_table,
 };