Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • boot/arch/arm32/src/mm.c

    r2e55443 r8f9d70b  
    7575        if (address >= AM335x_RAM_START && address < AM335x_RAM_END)
    7676                return 1;
     77#elif defined MACHINE_raspberrypi
     78        const unsigned long address = section << PTE_SECTION_SHIFT;
     79        if (address < BCM2835_RAM_END)
     80                return 1;
    7781#endif
    7882        return 0;
     
    113117static void init_boot_pt(void)
    114118{
     119#if defined MACHINE_raspberrypi
     120        const pfn_t split_page = 2048;
     121#else
    115122        const pfn_t split_page = PTL0_ENTRIES;
     123#endif
     124
    116125        /* Create 1:1 virtual-physical mapping (in lower 2 GB). */
    117126        pfn_t page;
    118127        for (page = 0; page < split_page; page++)
    119128                init_ptl0_section(&boot_pt[page], page);
    120        
     129
     130#if defined MACHINE_raspberrypi
     131        for (; page < PTL0_ENTRIES; page++)
     132                init_ptl0_section(&boot_pt[page], page - split_page);
     133#endif 
    121134        asm volatile (
    122135                "mcr p15, 0, %[pt], c2, c0, 0\n"
Note: See TracChangeset for help on using the changeset viewer.