diff options
Diffstat (limited to 'arch/arm/plat-samsung/s5p-dev-mfc.c')
-rw-r--r-- | arch/arm/plat-samsung/s5p-dev-mfc.c | 42 |
1 files changed, 41 insertions, 1 deletions
diff --git a/arch/arm/plat-samsung/s5p-dev-mfc.c b/arch/arm/plat-samsung/s5p-dev-mfc.c index 5ec104b5408b..a93fb6fb6606 100644 --- a/arch/arm/plat-samsung/s5p-dev-mfc.c +++ b/arch/arm/plat-samsung/s5p-dev-mfc.c | |||
@@ -18,10 +18,50 @@ | |||
18 | #include <linux/of.h> | 18 | #include <linux/of.h> |
19 | 19 | ||
20 | #include <mach/map.h> | 20 | #include <mach/map.h> |
21 | #include <mach/irqs.h> | ||
21 | #include <plat/devs.h> | 22 | #include <plat/devs.h> |
22 | #include <plat/irqs.h> | ||
23 | #include <plat/mfc.h> | 23 | #include <plat/mfc.h> |
24 | 24 | ||
25 | static struct resource s5p_mfc_resource[] = { | ||
26 | [0] = DEFINE_RES_MEM(S5P_PA_MFC, SZ_64K), | ||
27 | [1] = DEFINE_RES_IRQ(IRQ_MFC), | ||
28 | }; | ||
29 | |||
30 | struct platform_device s5p_device_mfc = { | ||
31 | .name = "s5p-mfc", | ||
32 | .id = -1, | ||
33 | .num_resources = ARRAY_SIZE(s5p_mfc_resource), | ||
34 | .resource = s5p_mfc_resource, | ||
35 | }; | ||
36 | |||
37 | /* | ||
38 | * MFC hardware has 2 memory interfaces which are modelled as two separate | ||
39 | * platform devices to let dma-mapping distinguish between them. | ||
40 | * | ||
41 | * MFC parent device (s5p_device_mfc) must be registered before memory | ||
42 | * interface specific devices (s5p_device_mfc_l and s5p_device_mfc_r). | ||
43 | */ | ||
44 | |||
45 | struct platform_device s5p_device_mfc_l = { | ||
46 | .name = "s5p-mfc-l", | ||
47 | .id = -1, | ||
48 | .dev = { | ||
49 | .parent = &s5p_device_mfc.dev, | ||
50 | .dma_mask = &s5p_device_mfc_l.dev.coherent_dma_mask, | ||
51 | .coherent_dma_mask = DMA_BIT_MASK(32), | ||
52 | }, | ||
53 | }; | ||
54 | |||
55 | struct platform_device s5p_device_mfc_r = { | ||
56 | .name = "s5p-mfc-r", | ||
57 | .id = -1, | ||
58 | .dev = { | ||
59 | .parent = &s5p_device_mfc.dev, | ||
60 | .dma_mask = &s5p_device_mfc_r.dev.coherent_dma_mask, | ||
61 | .coherent_dma_mask = DMA_BIT_MASK(32), | ||
62 | }, | ||
63 | }; | ||
64 | |||
25 | struct s5p_mfc_reserved_mem { | 65 | struct s5p_mfc_reserved_mem { |
26 | phys_addr_t base; | 66 | phys_addr_t base; |
27 | unsigned long size; | 67 | unsigned long size; |