Merge branch 'stable-3.2' into pandora-3.2
[pandora-kernel.git] / arch / arm / kernel / head.S
index 3fe4e45..441b004 100644 (file)
@@ -221,6 +221,7 @@ __create_page_tables:
        /*
         * Then map boot params address in r2 or
         * the first 1MB of ram if boot params address is not specified.
+        * We map 2 sections in case the ATAGs/DTB crosses a section boundary.
         */
        mov     r0, r2, lsr #SECTION_SHIFT
        movs    r0, r0, lsl #SECTION_SHIFT
@@ -229,6 +230,8 @@ __create_page_tables:
        add     r3, r3, #PAGE_OFFSET
        add     r3, r4, r3, lsr #(SECTION_SHIFT - PMD_ORDER)
        orr     r6, r7, r0
+       str     r6, [r3], #1 << PMD_ORDER
+       add     r6, r6, #1 << SECTION_SHIFT
        str     r6, [r3]
 
 #ifdef CONFIG_DEBUG_LL