Skip to content

Commit aa46e18

Browse files
Anshuman Khandualwilldeacon
authored andcommitted
arm64/mm: Drop redundant addr increment in set_huge_pte_at()
The 'addr' need not be incremented in the loop because that is not going to be used subsequently. Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Will Deacon <will@kernel.org> Cc: Ryan Roberts <ryan.roberts@arm.com> Cc: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org Reviewed-by: Dev Jain <dev.jain@arm.com> Signed-off-by: Anshuman Khandual <anshuman.khandual@arm.com> Link: https://lore.kernel.org/r/20250716035432.293682-1-anshuman.khandual@arm.com Signed-off-by: Will Deacon <will@kernel.org>
1 parent d7ce7e3 commit aa46e18

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

arch/arm64/mm/hugetlbpage.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ void set_huge_pte_at(struct mm_struct *mm, unsigned long addr,
225225
ncontig = num_contig_ptes(sz, &pgsize);
226226

227227
if (!pte_present(pte)) {
228-
for (i = 0; i < ncontig; i++, ptep++, addr += pgsize)
228+
for (i = 0; i < ncontig; i++, ptep++)
229229
__set_ptes_anysz(mm, ptep, pte, 1, pgsize);
230230
return;
231231
}

0 commit comments

Comments
 (0)