Changeset 06e6805 in mainline for arch/ppc32/src
- Timestamp:
- 2006-03-14T11:08:44Z (20 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 4bb4836d
- Parents:
- d1f8a87
- Location:
- arch/ppc32/src
- Files:
-
- 3 edited
- 1 moved
-
boot/boot.S (moved) (moved from arch/ppc32/src/start.S ) (1 diff)
-
console.c (modified) (1 diff)
-
mm/memory_init.c (modified) (1 diff)
-
ppc32.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
arch/ppc32/src/boot/boot.S
rd1f8a87 r06e6805 29 29 #include <arch/asm/regname.h> 30 30 #include <arch/asm/spr.h> 31 #include <arch/boot/boot.h> 32 #include <arch/boot/memmap.h> 31 33 32 34 .section K_TEXT_START 33 35 34 36 .global kernel_image_start 37 kernel_image_start: 38 39 # r10 contains physical address to memmap_t 40 # from boot loader 41 42 lis r4, 0x80000000@ha 43 addi r4, r4, 0x80000000@l 44 45 add r10, r10, r4 35 46 36 kernel_image_start: 47 lis r4, memmap@ha 48 addi r4, r4, memmap@l # r4 = memmap 49 50 lwz r5, 0(r10) # memmap->total 51 stw r5, 0(r4) 52 53 lwzu r5, 4(r10) # memmap->count 54 stwu r5, 4(r4) 55 56 cmpwi r5, 0 57 beq memmap_end 58 59 mtctr r5 60 memmap_loop: 61 62 lwzu r5, 4(r10) # memmap->zones[i].start 63 stwu r5, 4(r4) 64 65 lwzu r5, 4(r10) # memmap->zones[i].size 66 stwu r5, 4(r4) 67 68 bdnz memmap_loop 69 memmap_end: 70 37 71 b main_bsp -
arch/ppc32/src/console.c
rd1f8a87 r06e6805 37 37 { 38 38 /* TODO: PCI detection etc. etc. - this is fine in PearPC for now */ 39 fb_init(0x 84000000, 800, 600, 4);39 fb_init(0xf0000000, 800, 600, 4); 40 40 } -
arch/ppc32/src/mm/memory_init.c
rd1f8a87 r06e6805 27 27 */ 28 28 29 #include <arch/boot/memmap.h> 29 30 #include <arch/mm/memory_init.h> 30 31 #include <typedefs.h> 32 #include <print.h> 33 34 memmap_t memmap; 35 31 36 32 37 size_t get_memory_size(void) 33 38 { 34 return 0;39 return memmap.total; 35 40 } 41 42 43 void memory_print_map(void) 44 { 45 count_t i; 46 47 for (i = 0; i < memmap.count; i++) 48 printf("base: %L size: %L\n", memmap.zones[i].start, memmap.zones[i].size); 49 } -
arch/ppc32/src/ppc32.c
rd1f8a87 r06e6805 30 30 #include <arch/console.h> 31 31 32 #include <arch/mm/memory_init.h> 33 32 34 void arch_pre_mm_init(void) 33 35 { … … 41 43 void arch_pre_smp_init(void) 42 44 { 45 memory_print_map(); 43 46 } 44 47
Note:
See TracChangeset
for help on using the changeset viewer.
