simpleboot.c (96916090f488986a4ebb8e9ffa6a3b50881d5ccd) | simpleboot.c (d58577d8f36f66dbb5dec30fc01dfddda0cfd1fa) |
---|---|
1/* 2 * The simple platform -- for booting when firmware doesn't supply a device 3 * tree or any platform configuration information. 4 * All data is extracted from an embedded device tree 5 * blob. 6 * 7 * Authors: Scott Wood <scottwood@freescale.com> 8 * Grant Likely <grant.likely@secretlab.ca> --- 9 unchanged lines hidden (view full) --- 18#include "ops.h" 19#include "types.h" 20#include "io.h" 21#include "stdio.h" 22#include "libfdt/libfdt.h" 23 24BSS_STACK(4*1024); 25 | 1/* 2 * The simple platform -- for booting when firmware doesn't supply a device 3 * tree or any platform configuration information. 4 * All data is extracted from an embedded device tree 5 * blob. 6 * 7 * Authors: Scott Wood <scottwood@freescale.com> 8 * Grant Likely <grant.likely@secretlab.ca> --- 9 unchanged lines hidden (view full) --- 18#include "ops.h" 19#include "types.h" 20#include "io.h" 21#include "stdio.h" 22#include "libfdt/libfdt.h" 23 24BSS_STACK(4*1024); 25 |
26extern int platform_specific_init(void) __attribute__((weak)); 27 |
|
26void platform_init(unsigned long r3, unsigned long r4, unsigned long r5, 27 unsigned long r6, unsigned long r7) 28{ 29 const u32 *na, *ns, *reg, *timebase; 30 u64 memsize64; 31 int node, size, i; 32 33 /* Make sure FDT blob is sane */ --- 41 unchanged lines hidden (view full) --- 75 if (timebase && (size == 4)) 76 timebase_period_ns = 1000000000 / *timebase; 77 78 /* Now we have the memory size; initialize the heap */ 79 simple_alloc_init(_end, memsize64 - (unsigned long)_end, 32, 64); 80 81 /* prepare the device tree and find the console */ 82 fdt_init(_dtb_start); | 28void platform_init(unsigned long r3, unsigned long r4, unsigned long r5, 29 unsigned long r6, unsigned long r7) 30{ 31 const u32 *na, *ns, *reg, *timebase; 32 u64 memsize64; 33 int node, size, i; 34 35 /* Make sure FDT blob is sane */ --- 41 unchanged lines hidden (view full) --- 77 if (timebase && (size == 4)) 78 timebase_period_ns = 1000000000 / *timebase; 79 80 /* Now we have the memory size; initialize the heap */ 81 simple_alloc_init(_end, memsize64 - (unsigned long)_end, 32, 64); 82 83 /* prepare the device tree and find the console */ 84 fdt_init(_dtb_start); |
85 86 if (platform_specific_init) 87 platform_specific_init(); 88 |
|
83 serial_console_init(); 84} | 89 serial_console_init(); 90} |