From: huxiang <huxiang@xxxxxxxxxxxxx> Subject: mm/page_alloc: redundant definition variables of pfn in for loop This variable pfn is defined repeatedly, so it can be deleted. Link: https://lkml.kernel.org/r/20210401022802.10358-1-huxiang@xxxxxxxxxxxxx Signed-off-by: huxiang <huxiang@xxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- mm/page_alloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/mm/page_alloc.c~mm-page_alloc-redundant-definition-variables-of-pfn-in-for-loop +++ a/mm/page_alloc.c @@ -3322,7 +3322,7 @@ void free_unref_page_list(struct list_he local_irq_save(flags); list_for_each_entry_safe(page, next, list, lru) { - unsigned long pfn = page_private(page); + pfn = page_private(page); set_page_private(page, 0); trace_mm_page_free_batched(page); _