Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 356180
b: refs/heads/master
c: 95c9608
h: refs/heads/master
v: v3
  • Loading branch information
H. Peter Anvin committed Feb 14, 2013
1 parent 7c73113 commit 72f309b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ff52c3b02b3f73178bfe0c219cd22abdcb0e46c3
refs/heads/master: 95c9608478d639dcffc14ea47b31bff021a99ed1
13 changes: 9 additions & 4 deletions trunk/arch/x86/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -608,8 +608,6 @@ static __init void reserve_ibft_region(void)
memblock_reserve(addr, size);
}

static unsigned reserve_low = CONFIG_X86_RESERVE_LOW << 10;

static bool __init snb_gfx_workaround_needed(void)
{
#ifdef CONFIG_PCI
Expand Down Expand Up @@ -698,8 +696,7 @@ static void __init trim_bios_range(void)
* since some BIOSes are known to corrupt low memory. See the
* Kconfig help text for X86_RESERVE_LOW.
*/
e820_update_range(0, ALIGN(reserve_low, PAGE_SIZE),
E820_RAM, E820_RESERVED);
e820_update_range(0, PAGE_SIZE, E820_RAM, E820_RESERVED);

/*
* special case: Some BIOSen report the PC BIOS
Expand All @@ -711,6 +708,8 @@ static void __init trim_bios_range(void)
sanitize_e820_map(e820.map, ARRAY_SIZE(e820.map), &e820.nr_map);
}

static unsigned reserve_low = CONFIG_X86_RESERVE_LOW << 10;

static int __init parse_reservelow(char *p)
{
unsigned long long size;
Expand All @@ -733,6 +732,11 @@ static int __init parse_reservelow(char *p)

early_param("reservelow", parse_reservelow);

static void __init trim_low_memory_range(void)
{
memblock_reserve(0, ALIGN(reserve_low, PAGE_SIZE));
}

/*
* Determine if we were loaded by an EFI loader. If so, then we have also been
* passed the efi memmap, systab, etc., so we should use these data structures
Expand Down Expand Up @@ -987,6 +991,7 @@ void __init setup_arch(char **cmdline_p)
setup_real_mode();

trim_platform_memory_ranges();
trim_low_memory_range();

init_gbpages();

Expand Down

0 comments on commit 72f309b

Please sign in to comment.