From d1a4be630fb068f251d64b62919f143c49ca8057 Mon Sep 17 00:00:00 2001 From: Ingo Molnar Date: Fri, 18 Apr 2008 21:32:22 +0200 Subject: [PATCH] x86 PAT: fix mmap() of holes do not return a -EINVAL when mmap()-ing PCI holes. Signed-off-by: Ingo Molnar Acked-by: Venkatesh Pallipadi Acked-by: Suresh Siddha Acked-by: H. Peter Anvin Acked-by: Thomas Gleixner Acked-by: Arjan van de Ven --- arch/x86/mm/pageattr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/mm/pageattr.c b/arch/x86/mm/pageattr.c index 7d9517abc9af..f7823a172868 100644 --- a/arch/x86/mm/pageattr.c +++ b/arch/x86/mm/pageattr.c @@ -542,7 +542,7 @@ static int __change_page_attr(struct cpa_data *cpa, int primary) repeat: kpte = lookup_address(address, &level); if (!kpte) - return primary ? -EINVAL : 0; + return 0; old_pte = *kpte; if (!pte_val(old_pte)) { -- 2.20.1