ralink: update patches
[openwrt.git] / target / linux / ramips / patches-3.9 / 0205-owrt-MIPS-add-OWRTDTB-secion.patch
1 From 6beb1af1b1475478c8f275b9579c9ebe4dad2904 Mon Sep 17 00:00:00 2001
2 From: John Crispin <blogic@openwrt.org>
3 Date: Tue, 19 Mar 2013 10:16:42 +0100
4 Subject: [PATCH 205/208] owrt: MIPS: add OWRTDTB secion
5
6 Signed-off-by: John Crispin <blogic@openwrt.org>
7 ---
8  arch/mips/kernel/head.S   |    3 +++
9  arch/mips/ralink/Makefile |    2 +-
10  arch/mips/ralink/of.c     |    4 +++-
11  3 files changed, 7 insertions(+), 2 deletions(-)
12
13 --- a/arch/mips/kernel/head.S
14 +++ b/arch/mips/kernel/head.S
15 @@ -146,6 +146,9 @@ EXPORT(__image_cmdline)
16         .fill   0x400
17  #endif /* CONFIG_IMAGE_CMDLINE_HACK */
18  
19 +       .ascii  "OWRTDTB:"
20 +       EXPORT(__image_dtb)
21 +       .fill   0x4000
22         __REF
23  
24  NESTED(kernel_entry, 16, sp)                   # kernel entry point
25 --- a/arch/mips/ralink/Makefile
26 +++ b/arch/mips/ralink/Makefile
27 @@ -15,4 +15,4 @@ obj-$(CONFIG_SOC_MT7620) += mt7620.o
28  
29  obj-$(CONFIG_EARLY_PRINTK) += early_printk.o
30  
31 -obj-y += dts/
32 +#obj-y += dts/
33 --- a/arch/mips/ralink/of.c
34 +++ b/arch/mips/ralink/of.c
35 @@ -77,6 +77,8 @@ void __init device_tree_init(void)
36         free_bootmem(base, size);
37  }
38  
39 +extern struct boot_param_header __image_dtb;
40 +
41  void __init plat_mem_setup(void)
42  {
43         set_io_port_base(KSEG1);
44 @@ -85,7 +87,7 @@ void __init plat_mem_setup(void)
45          * Load the builtin devicetree. This causes the chosen node to be
46          * parsed resulting in our memory appearing
47          */
48 -       __dt_setup_arch(&__dtb_start);
49 +       __dt_setup_arch(&__image_dtb);
50  
51         if (soc_info.mem_size)
52                 add_memory_region(soc_info.mem_base, soc_info.mem_size,