mmc: sdhci-of: fix build on non-powerpc platforms
authorRob Herring <rob.herring@calxeda.com>
Tue, 16 Nov 2010 20:33:52 +0000 (14:33 -0600)
committerGrant Likely <grant.likely@secretlab.ca>
Fri, 14 Jan 2011 07:22:44 +0000 (00:22 -0700)
Explicitly include err.h, of_address.h and of_irq.h.
Make use of machine_is() conditional on PPC.

Signed-off-by: Rob Herring <rob.herring@calxeda.com>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
drivers/mmc/host/sdhci-of-core.c

index fa19d849a9202ad0a9390ee96fae6a3e9647594e..dd84124f4209314bd571a61a172cbbcf24285cf9 100644 (file)
@@ -13,6 +13,7 @@
  * your option) any later version.
  */
 
+#include <linux/err.h>
 #include <linux/module.h>
 #include <linux/init.h>
 #include <linux/io.h>
 #include <linux/delay.h>
 #include <linux/of.h>
 #include <linux/of_platform.h>
+#include <linux/of_address.h>
+#include <linux/of_irq.h>
 #include <linux/mmc/host.h>
+#ifdef CONFIG_PPC
 #include <asm/machdep.h>
+#endif
 #include "sdhci-of.h"
 #include "sdhci.h"
 
@@ -112,7 +117,11 @@ static bool __devinit sdhci_of_wp_inverted(struct device_node *np)
                return true;
 
        /* Old device trees don't have the wp-inverted property. */
+#ifdef CONFIG_PPC
        return machine_is(mpc837x_rdb) || machine_is(mpc837x_mds);
+#else
+       return false;
+#endif
 }
 
 static int __devinit sdhci_of_probe(struct platform_device *ofdev,