]> git.karo-electronics.de Git - linux-beck.git/commit
x86/mm: Fix gup_huge_p?d() to handle large PAT bit
authorToshi Kani <toshi.kani@hpe.com>
Thu, 17 Sep 2015 18:24:21 +0000 (12:24 -0600)
committerThomas Gleixner <tglx@linutronix.de>
Tue, 22 Sep 2015 19:27:33 +0000 (21:27 +0200)
commitdaf3e35c5888e8bd6a2f5ed15ed392b2df362ecf
tree25cd9853a171e0691de368b90336b8b8d29e47b7
parent34437e67a6727885bdf6cbfd8441b1ac43a1ee65
x86/mm: Fix gup_huge_p?d() to handle large PAT bit

gup_huge_pud() and gup_huge_pmd() cast *pud and *pmd to *pte,
and use pte_xxx() interfaces to obtain the flags and PFN.
However, the pte_xxx() interface does not handle the large
PAT bit properly for PUD/PMD.

Fix gup_huge_pud() and gup_huge_pmd() to use pud_xxx() and
pmd_xxx() interfaces according to their type.

Signed-off-by: Toshi Kani <toshi.kani@hpe.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Juergen Gross <jgross@suse.com>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Konrad Wilk <konrad.wilk@oracle.com>
Cc: Robert Elliot <elliott@hpe.com>
Cc: linux-mm@kvack.org
Link: http://lkml.kernel.org/r/1442514264-12475-9-git-send-email-toshi.kani@hpe.com
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
arch/x86/mm/gup.c