Skip to content

Commit 73301e4

Browse files
Gavin Shanwilldeacon
authored andcommitted
arm64: tlb: Allow range operation for MAX_TLBI_RANGE_PAGES
MAX_TLBI_RANGE_PAGES pages is covered by SCALE#3 and NUM#31 and it's supported now. Allow TLBI RANGE operation when the number of pages is equal to MAX_TLBI_RANGE_PAGES in __flush_tlb_range_nosync(). Suggested-by: Marc Zyngier <[email protected]> Signed-off-by: Gavin Shan <[email protected]> Reviewed-by: Anshuman Khandual <[email protected]> Reviewed-by: Ryan Roberts <[email protected]> Reviewed-by: Catalin Marinas <[email protected]> Reviewed-by: Shaoqin Huang <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Will Deacon <[email protected]>
1 parent e07255d commit 73301e4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

arch/arm64/include/asm/tlbflush.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -446,11 +446,11 @@ static inline void __flush_tlb_range_nosync(struct vm_area_struct *vma,
446446
* When not uses TLB range ops, we can handle up to
447447
* (MAX_DVM_OPS - 1) pages;
448448
* When uses TLB range ops, we can handle up to
449-
* (MAX_TLBI_RANGE_PAGES - 1) pages.
449+
* MAX_TLBI_RANGE_PAGES pages.
450450
*/
451451
if ((!system_supports_tlb_range() &&
452452
(end - start) >= (MAX_DVM_OPS * stride)) ||
453-
pages >= MAX_TLBI_RANGE_PAGES) {
453+
pages > MAX_TLBI_RANGE_PAGES) {
454454
flush_tlb_mm(vma->vm_mm);
455455
return;
456456
}

0 commit comments

Comments
 (0)