]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
Merge remote-tracking branch 'dt-rh/for-next'
authorThierry Reding <treding@nvidia.com>
Mon, 21 Oct 2013 11:31:39 +0000 (13:31 +0200)
committerThierry Reding <treding@nvidia.com>
Mon, 21 Oct 2013 11:31:39 +0000 (13:31 +0200)
20 files changed:
1  2 
arch/arm/mm/init.c
arch/mips/ralink/of.c
arch/powerpc/platforms/8xx/tqm8xx_setup.c
arch/powerpc/platforms/powernv/opal.c
arch/powerpc/sysdev/mpic.c
drivers/cpufreq/pasemi-cpufreq.c
drivers/crypto/caam/ctrl.c
drivers/crypto/talitos.c
drivers/mtd/nand/fsl_elbc_nand.c
drivers/mtd/nand/fsl_ifc_nand.c
drivers/net/ethernet/freescale/gianfar.c
drivers/net/ethernet/freescale/ucc_geth.c
drivers/net/ethernet/ibm/emac/core.c
drivers/net/ethernet/xilinx/ll_temac_main.c
drivers/of/address.c
drivers/of/base.c
drivers/of/fdt.c
drivers/spi/spi-mpc512x-psc.c
sound/soc/fsl/fsl_dma.c
sound/soc/fsl/mpc5200_dma.c

Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
index a4fa9ad31b8f7cfb62f45abf47ada0649d87b867,5c479104fc677a2169c3f49b02ebde8435365fdd..2fa024b97c4350c680e384c645dc17d0fc5dc177
@@@ -801,4 -910,39 +909,28 @@@ void __init unflatten_device_tree(void
        of_alias_scan(early_init_dt_alloc_memory_arch);
  }
  
+ /**
+  * unflatten_and_copy_device_tree - copy and create tree of device_nodes from flat blob
+  *
+  * Copies and unflattens the device-tree passed by the firmware, creating the
+  * tree of struct device_node. It also fills the "name" and "type"
+  * pointers of the nodes so the normal device-tree walking functions
+  * can be used. This should only be used when the FDT memory has not been
+  * reserved such is the case when the FDT is built-in to the kernel init
+  * section. If the FDT memory is reserved already then unflatten_device_tree
+  * should be used instead.
+  */
+ void __init unflatten_and_copy_device_tree(void)
+ {
+       int size = __be32_to_cpu(initial_boot_params->totalsize);
+       void *dt = early_init_dt_alloc_memory_arch(size,
+               __alignof__(struct boot_param_header));
+       if (dt) {
+               memcpy(dt, initial_boot_params, size);
+               initial_boot_params = dt;
+       }
+       unflatten_device_tree();
+ }
  #endif /* CONFIG_OF_EARLY_FLATTREE */
 -
 -/* Feed entire flattened device tree into the random pool */
 -static int __init add_fdt_randomness(void)
 -{
 -      if (initial_boot_params)
 -              add_device_randomness(initial_boot_params,
 -                              be32_to_cpu(initial_boot_params->totalsize));
 -
 -      return 0;
 -}
 -core_initcall(add_fdt_randomness);
Simple merge
Simple merge
Simple merge