提交 5d3c8b21 编写于 作者: A Andi Kleen 提交者: Ingo Molnar

x86: CPA: fix gbpages support in try_preserve_large_page

[ mingo@elte.hu: while gbpages cannot be enabled on mainline currently,
  keep the code uptodate and this fix is easy enough. ]

Use correct page sizes and masks for GB pages in try_preserve_large_page()

This prevents a boot hang on a GB capable system with CONFIG_DIRECT_GBPAGES
enabled.
Signed-off-by: NAndi Kleen <ak@suse.de>
Signed-off-by: NIngo Molnar <mingo@elte.hu>
Signed-off-by: NThomas Gleixner <tglx@linutronix.de>
上级 2b540781
......@@ -275,8 +275,8 @@ try_preserve_large_page(pte_t *kpte, unsigned long address,
break;
#ifdef CONFIG_X86_64
case PG_LEVEL_1G:
psize = PMD_PAGE_SIZE;
pmask = PMD_PAGE_MASK;
psize = PUD_PAGE_SIZE;
pmask = PUD_PAGE_MASK;
break;
#endif
default:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册