Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
x86/init: fix build with CONFIG_SWAP=n
The introduction of generic_max_swapfile_size and arch-specific versions has broken linking on x86 with CONFIG_SWAP=n due to undefined reference to 'generic_max_swapfile_size'. Fix it by compiling the x86-specific max_swapfile_size() only with CONFIG_SWAP=y. Reported-by: Tomas Pruzina <[email protected]> Fixes: 377eeaa ("x86/speculation/l1tf: Limit swap file size to MAX_PA/2") Signed-off-by: Vlastimil Babka <[email protected]> Cc: [email protected] Signed-off-by: Linus Torvalds <[email protected]>
- Loading branch information