Changeset bcad855 in mainline for kernel/arch/mips32/src


Ignore:
Timestamp:
2012-12-06T23:03:08Z (13 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
3f69f63d
Parents:
295732b
Message:

Use the SDRAM size as passed from YAMON.

  • Do not probe memory beyond the end of SDRAM.
Location:
kernel/arch/mips32/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/mips32/src/mips32.c

    r295732b rbcad855  
    7171size_t cpu_count = 0;
    7272
     73#if defined(MACHINE_lmalta) || defined(MACHINE_bmalta)
     74size_t sdram_size = 0;
     75#endif
     76
    7377/** Performs mips32-specific initialization before main_bsp() is called. */
    7478void arch_pre_main(void *entry __attribute__((unused)), bootinfo_t *bootinfo)
     
    8892                        cpu_count++;
    8993        }
     94
     95#if defined(MACHINE_lmalta) || defined(MACHINE_bmalta)
     96        sdram_size = bootinfo->sdram_size;
     97#endif
    9098}
    9199
  • kernel/arch/mips32/src/mm/frame.c

    r295732b rbcad855  
    4141#include <config.h>
    4242#include <arch/drivers/msim.h>
     43#include <arch/arch.h>
    4344#include <print.h>
    4445
     
    8283        /* MSIM device (dkeyboard) */
    8384        if (frame == (KA2PA(MSIM_KBD_ADDRESS) >> ZERO_PAGE_WIDTH))
     85                return false;
     86#endif
     87
     88#if defined(MACHINE_lmalta) || defined(MACHINE_bmalta)
     89        if (frame >= (sdram_size >> ZERO_PAGE_WIDTH))
    8490                return false;
    8591#endif
Note: See TracChangeset for help on using the changeset viewer.