History

x86: respect memory size limiting via mem= parameter

When limiting memory size via kernel parameter "mem=" this should be respected even in case of memory made accessible via a PCI card. Today this kind of memory won't be made usable in initial memory setup as the memory won't be visible in E820 map, but it might be added when adding PCI devices due to corresponding ACPI table entries. Not respecting "mem=" can be corrected by adding a global max_mem_size variable set by parse_memopt() which will result in rejecting adding memory areas resulting in a memory size above the allowed limit.

Juergen Gross committed 7 years ago

Commit 357b4da1 parent 068e79f3 files · +13 −0Browse files

Showing the changes to include/linux (1 of 3 files). Show all

Unified · Split

include/linux/memory_hotplug.h+2−0
@@ -100,6 +100,8 @@ extern void __online_page_free(struct page *page); · 99 unmodified lines
100100
101101 extern int try_online_node(int nid);
102102
103+extern u64 max_mem_size;
104+
103105 extern bool memhp_auto_online;
104106 /* If movable_node boot option specified */
105107 extern bool movable_node_enabled;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t