From 9e3288dc9a94fab5ea87db42177d3a9e0345a614 Mon Sep 17 00:00:00 2001 From: Grant Likely Date: Tue, 8 Jun 2010 07:48:26 -0600 Subject: of/device: Fix build errors for non-ppc and non-microblaze Only powerpc and microblaze supply (struct device *)->archdata.dma_mask. This patch stops referencing it on other architectures. Signed-off-by: Grant Likely --- drivers/of/platform.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'drivers/of/platform.c') diff --git a/drivers/of/platform.c b/drivers/of/platform.c index c52a798684a9..9d3d932bcb6f 100644 --- a/drivers/of/platform.c +++ b/drivers/of/platform.c @@ -16,7 +16,9 @@ #include #include #include +#include #include +#include #include #if defined(CONFIG_PPC_DCR) @@ -511,7 +513,9 @@ struct of_device *of_device_alloc(struct device_node *np, } dev->dev.of_node = of_node_get(np); +#if defined(CONFIG_PPC) || defined(CONFIG_MICROBLAZE) dev->dev.dma_mask = &dev->archdata.dma_mask; +#endif dev->dev.parent = parent; dev->dev.release = of_release_dev; @@ -540,7 +544,9 @@ struct of_device *of_platform_device_create(struct device_node *np, if (!dev) return NULL; +#if defined(CONFIG_PPC) || defined(CONFIG_MICROBLAZE) dev->archdata.dma_mask = 0xffffffffUL; +#endif dev->dev.coherent_dma_mask = DMA_BIT_MASK(32); dev->dev.bus = &of_platform_bus_type; -- cgit v1.2.3