Patch "arm64: mm: avoid name clash in __page_to_voff()" has been added to the 4.9-stable tree
Subsystems (2)
This is a note to let you know that I've just added the patch titled
arm64: mm: avoid name clash in __page_to_voff()
to the 4.9-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
arm64-mm-avoid-name-clash-in-__page_to_voff.patch
and it can be found in the queue-4.9 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From
1c8a946bf3754a59cba1fc373949a8114bfe5aaaMon Sep 17 00:00:00 2001
From: Oleksandr Andrushchenko <[email protected]>
Date: Wed, 18 Jan 2017 09:09:25 +0200
Subject: arm64: mm: avoid name clash in __page_to_voff()
From: Oleksandr Andrushchenko <[email protected]>
commit 1c8a946bf3754a59cba1fc373949a8114bfe5aaa upstream.
The arm64 __page_to_voff() macro takes a parameter called 'page', and also refers to 'struct page'. Thus, if the value passed in is not called 'page', we'll refer to the wrong struct name (which might not exist).
--- arch/arm64/include/asm/memory.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/include/asm/memory.h +1 -1
@@ -217,7 +217,7 @@ static inline void *phys_to_virt(phys_ad#define _virt_addr_valid (kaddr) pfn_valid(__pa(kaddr) >> PAGE_SHIFT)#else #define __virt_to_pgoff (kaddr) (((u64)(kaddr) & ~PAGE_OFFSET) / PAGE_SIZE * sizeof(struct page)) -#define __page_to_voff (page) (((u64)(page) & ~VMEMMAP_START) * PAGE_SIZE / sizeof(struct page)) +#define __page_to_voff (kaddr) (((u64)(kaddr) & ~VMEMMAP_START) * PAGE_SIZE / sizeof(struct page))#define page_to_virt (page) ((void *)((__page_to_voff(page)) | PAGE_OFFSET))#define virt_to_page (vaddr) ((struct page *)((__virt_to_pgoff(vaddr)) | VMEMMAP_START))
Patches currently in stable-queue which might be from [email protected] are
queue-4.9/arm64-mm-avoid-name-clash-in-__page_to_voff.patch