aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/of/platform.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/of/platform.c')
-rw-r--r--drivers/of/platform.c6
1 files changed, 6 insertions, 0 deletions
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 @@
16#include <linux/device.h> 16#include <linux/device.h>
17#include <linux/dma-mapping.h> 17#include <linux/dma-mapping.h>
18#include <linux/slab.h> 18#include <linux/slab.h>
19#include <linux/of_address.h>
19#include <linux/of_device.h> 20#include <linux/of_device.h>
21#include <linux/of_irq.h>
20#include <linux/of_platform.h> 22#include <linux/of_platform.h>
21 23
22#if defined(CONFIG_PPC_DCR) 24#if defined(CONFIG_PPC_DCR)
@@ -511,7 +513,9 @@ struct of_device *of_device_alloc(struct device_node *np,
511 } 513 }
512 514
513 dev->dev.of_node = of_node_get(np); 515 dev->dev.of_node = of_node_get(np);
516#if defined(CONFIG_PPC) || defined(CONFIG_MICROBLAZE)
514 dev->dev.dma_mask = &dev->archdata.dma_mask; 517 dev->dev.dma_mask = &dev->archdata.dma_mask;
518#endif
515 dev->dev.parent = parent; 519 dev->dev.parent = parent;
516 dev->dev.release = of_release_dev; 520 dev->dev.release = of_release_dev;
517 521
@@ -540,7 +544,9 @@ struct of_device *of_platform_device_create(struct device_node *np,
540 if (!dev) 544 if (!dev)
541 return NULL; 545 return NULL;
542 546
547#if defined(CONFIG_PPC) || defined(CONFIG_MICROBLAZE)
543 dev->archdata.dma_mask = 0xffffffffUL; 548 dev->archdata.dma_mask = 0xffffffffUL;
549#endif
544 dev->dev.coherent_dma_mask = DMA_BIT_MASK(32); 550 dev->dev.coherent_dma_mask = DMA_BIT_MASK(32);
545 dev->dev.bus = &of_platform_bus_type; 551 dev->dev.bus = &of_platform_bus_type;
546 552