summaryrefslogtreecommitdiff
path: root/drivers/of/Kconfig
diff options
context:
space:
mode:
authorMarek Szyprowski <m.szyprowski@samsung.com>2013-08-26 14:43:10 +0200
committerMarek Szyprowski <m.szyprowski@samsung.com>2013-08-27 10:53:44 +0200
commit9d8eab7af79cb4ce2de5de39f82c455b1f796963 (patch)
treefd26c89bad9e8bdde9af51b47f5bb476e87a1b52 /drivers/of/Kconfig
parent57d74bcf3072b65bde5aa540cedc976a75c48e5c (diff)
drivers: of: add initialization code for dma reserved memory
This patch adds device tree support for contiguous and reserved memory regions defined in device tree. Large memory blocks can be reliably reserved only during early boot. This must happen before the whole memory management subsystem is initialized, because we need to ensure that the given contiguous blocks are not yet allocated by kernel. Also it must happen before kernel mappings for the whole low memory are created, to ensure that there will be no mappings (for reserved blocks) or mapping with special properties can be created (for CMA blocks). This all happens before device tree structures are unflattened, so we need to get reserved memory layout directly from fdt. Later, those reserved memory regions are assigned to devices on each device structure initialization. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Acked-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Michal Nazarewicz <mina86@mina86.com> Acked-by: Tomasz Figa <t.figa@samsung.com> Acked-by: Stephen Warren <swarren@nvidia.com> Reviewed-by: Rob Herring <rob.herring@calxeda.com>
Diffstat (limited to 'drivers/of/Kconfig')
-rw-r--r--drivers/of/Kconfig6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/of/Kconfig b/drivers/of/Kconfig
index 80e5c13b930d..730965157b2c 100644
--- a/drivers/of/Kconfig
+++ b/drivers/of/Kconfig
@@ -80,4 +80,10 @@ config OF_MTD
depends on MTD
def_bool y
+config OF_RESERVED_MEM
+ depends on OF_FLATTREE && (DMA_CMA || (HAVE_GENERIC_DMA_COHERENT && HAVE_MEMBLOCK))
+ def_bool y
+ help
+ Initialization code for DMA reserved memory
+
endmenu # OF