Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

um: fix __pa/__va macro expansion problem

Proper parentheses around arguments needed, especially as the macros use
a high-precedence cast operator on the argument.

+2 -2
+2 -2
include/asm-um/page.h
··· 104 104 * casting is the right thing, but 32-bit UML can't have 64-bit virtual 105 105 * addresses 106 106 */ 107 - #define __pa(virt) to_phys((void *) (unsigned long) virt) 108 - #define __va(phys) to_virt((unsigned long) phys) 107 + #define __pa(virt) to_phys((void *) (unsigned long) (virt)) 108 + #define __va(phys) to_virt((unsigned long) (phys)) 109 109 110 110 #define page_to_pfn(page) ((page) - mem_map) 111 111 #define pfn_to_page(pfn) (mem_map + (pfn))