mirror of
https://github.com/memtest86plus/memtest86plus.git
synced 2024-11-27 10:00:17 -06:00
Make sure the bootparams structure remains accessible during startup.
Once we start remapping other regions, it's possible it could get overlaid.
This commit is contained in:
parent
9fca23105a
commit
03464dce85
@ -16,6 +16,7 @@
|
|||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
|
|
||||||
#include "boot.h"
|
#include "boot.h"
|
||||||
|
#include "bootparams.h"
|
||||||
|
|
||||||
#include "cache.h"
|
#include "cache.h"
|
||||||
#include "cpuid.h"
|
#include "cpuid.h"
|
||||||
@ -170,6 +171,9 @@ static bool set_load_addr(uintptr_t *load_addr, size_t program_size, uintptr_t l
|
|||||||
|
|
||||||
static void global_init(void)
|
static void global_init(void)
|
||||||
{
|
{
|
||||||
|
// This is the first region we map, so is guaranteed not to fail.
|
||||||
|
boot_params_addr = map_region(boot_params_addr, sizeof(boot_params_t), true);
|
||||||
|
|
||||||
floppy_off();
|
floppy_off();
|
||||||
|
|
||||||
cache_on();
|
cache_on();
|
||||||
|
Loading…
Reference in New Issue
Block a user