]> Git Repo - linux.git/commitdiff
of: reserved-memory: ignore disabled memory-region nodes
authorKrishna Reddy <[email protected]>
Wed, 22 May 2019 10:47:11 +0000 (16:17 +0530)
committerRob Herring <[email protected]>
Fri, 24 May 2019 20:53:23 +0000 (15:53 -0500)
Ignore disabled nodes in the memory-region
nodes list and continue to initialize the rest
of enabled nodes.

Check if the "reserved-memory" node is available
and if it's not available, return 0 to ignore the
"reserved-memory" node and continue parsing with
next node in memory-region nodes list.

Signed-off-by: Krishna Reddy <[email protected]>
Signed-off-by: Puneet Saxena <[email protected]>
Signed-off-by: Rob Herring <[email protected]>
drivers/of/of_reserved_mem.c

index 89e190e94af7558e9c66e26eee530bd7887d5d31..7989703b883ce64ebe9fa8f58a7c718b6dd10db1 100644 (file)
@@ -324,6 +324,9 @@ int of_reserved_mem_device_init_by_idx(struct device *dev,
        if (!target)
                return -ENODEV;
 
+       if (!of_device_is_available(target))
+               return 0;
+
        rmem = __find_rmem(target);
        of_node_put(target);
 
This page took 0.060006 seconds and 4 git commands to generate.