linux-mips
[Top] [All Lists]

[PATCH] mips: Fix compilation warning

To: "david.daney@cavium.com" <david.daney@cavium.com>, "ralf@linux-mips.org" <ralf@linux-mips.org>
Subject: [PATCH] mips: Fix compilation warning
From: EUNBONG SONG <eunb.song@samsung.com>
Date: Mon, 20 May 2013 09:53:26 +0000 (GMT)
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>, "linux-mips@linux-mips.org" <linux-mips@linux-mips.org>
Dlp-filter: Pass
List-archive: <http://www.linux-mips.org/archives/linux-mips/>
List-help: <mailto:ecartis@linux-mips.org?Subject=help>
List-id: linux-mips <linux-mips.eddie.linux-mips.org>
List-owner: <mailto:ralf@linux-mips.org>
List-post: <mailto:linux-mips@linux-mips.org>
List-software: Ecartis version 1.0.0
List-subscribe: <mailto:ecartis@linux-mips.org?subject=subscribe%20linux-mips>
List-unsubscribe: <mailto:ecartis@linux-mips.org?subject=unsubscribe%20linux-mips>
Msgkey: 20130520095141724@eunb.song
Original-recipient: rfc822;linux-mips@linux-mips.org
Reply-to: eunb.song@samsung.com
Sender: linux-mips-bounce@linux-mips.org
Fix the following compilation warning:

mm/page_alloc.c: In function 'free_reserved_area':
mm/page_alloc.c:5162: warning: passing argument 1 of 'virt_to_phys' makes 
pointer from integer without a cast

Signed-off-by: Eunbong Song <eunb.song@samsung.com>
---
 arch/mips/include/asm/page.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/mips/include/asm/page.h b/arch/mips/include/asm/page.h
index ec1ca53..41640f1 100644
--- a/arch/mips/include/asm/page.h
+++ b/arch/mips/include/asm/page.h
@@ -197,7 +197,7 @@ typedef struct { unsigned long pgprot; } pgprot_t;
 
 #endif
 
-#define virt_to_page(kaddr)    pfn_to_page(PFN_DOWN(virt_to_phys(kaddr)))
+#define virt_to_page(kaddr)    pfn_to_page(PFN_DOWN(virt_to_phys((const 
volatile void *)(kaddr))))
 
 extern int __virt_addr_valid(const volatile void *kaddr);
 #define virt_addr_valid(kaddr)                                         \
-- 
1.7.0.4
<Prev in Thread] Current Thread [Next in Thread>