Skip to contentSkip to conversation

FAILED: patch "[PATCH] arm64: hugetlb: fix the wrong return value for" failed to apply to 4.9-stable tree

PATCH [email protected] 2 participants 3 messages Jan 17, 2017 – Jan 18, 2017

Subsystems (2)
lore
Share & tools
lore

[email protected]

author maintainer
#0 lore raw

The patch below does not apply to the 4.9-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.

thanks,

greg k-h

------------------ original commit in Linus's tree ------------------

Quoted 1 line

From 69d012345a1a32d3f03957f14d972efccc106a98 Mon Sep 17 00:00:00 2001

From: Huang Shijie <[email protected]>
Date: Wed, 11 Jan 2017 14:02:00 +0800
Subject: [PATCH] arm64: hugetlb: fix the wrong return value for
huge_ptep_set_access_flags

In current code, the @changed always returns the last one's status for the huge page with the contiguous bit set. This is really not what we want. Even one of the PTEs is changed, we should tell it to the caller.

This patch fixes this issue.

Fixes 66b3923a1a0f ("arm64: hugetlb: add support for PTE contiguous bit")
Cc <[email protected]> # 4.5.x-
arch/arm64/mm/hugetlbpage.c +1 -1
index 964b7549af5c..e25584d72396 100644
@@ -239,7 +239,7 @@ int huge_ptep_set_access_flags(struct vm_area_struct *vma,
 		ncontig = find_num_contig(vma->vm_mm, addr, cpte,
 					  *cpte, &pgsize);
 		for (i = 0; i < ncontig; ++i, ++cpte, addr += pgsize) {
-			changed = ptep_set_access_flags(vma, addr, cpte,
+			changed |= ptep_set_access_flags(vma, addr, cpte,
 							pfn_pte(pfn,
 								hugeprot),
 							dirty);
#1 lore raw

Hi Greg,

Quoted 2 lines · On Tue, Jan 17, 2017 at 10:47:05AM +0100, [email protected] wrote:

The patch below does not apply to the 4.9-stable tree.

Please try to apply two others patches before apply this one:
0c2f0afe3582 arm64: hugetlb: fix the wrong address for several functions 20156ce2365d arm64: hugetlb: remove the wrong pmd check in find_num_contig()

Thanks
Huang Shijie

Quoted 4 lines

If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.

author maintainer
#2 lore raw
Quoted 8 lines · Huang Shijie

Hi Greg,

Quoted 2 lines · On Tue, Jan 17, 2017 at 10:47:05AM +0100, [email protected] wrote:

The patch below does not apply to the 4.9-stable tree.

Please try to apply two others patches before apply this one:
0c2f0afe3582 arm64: hugetlb: fix the wrong address for several functions 20156ce2365d arm64: hugetlb: remove the wrong pmd check in find_num_contig()

Yes, that worked great, thanks.

greg k-h