Skip to contentSkip to conversation

kcore-use-registerd-physmem-information-fix2

PATCH In review Jiri Slaby 2 participants 2 messages Aug 21, 2009

Subsystems (2)
lore
Share & tools
lore

Jiri Slaby

author
#0 lore raw

PATCH 1/1 kcore-use-registerd-physmem-information-fix2

Fix this compilation warning on x86_64:
fs/proc/kcore.c: In function ‘kclist_add_private’:
fs/proc/kcore.c:175: warning: comparison between pointer and integer

Cc KAMEZAWA Hiroyuki <[email protected]>
---
 fs/proc/kcore.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
fs/proc/kcore.c +1 -1
index aabbc3a..98fcf17 100644
@@ -172,7 +172,7 @@ kclist_add_private(unsigned long pfn, unsigned long nr_pages, void *arg)
 		ent->size = ULONG_MAX - ent->addr;
 
 	/* cut when vmalloc() area is higher than direct-map area */
-	if (VMALLOC_START > __va(0)) {
+	if (VMALLOC_START > (unsigned long)__va(0)) {
 		if (ent->addr > VMALLOC_START)
 			goto free_out;
 		if (VMALLOC_START - ent->addr < ent->size)
Signature · 1 line
1.6.3.3
Reviewed-by on v1 1/1
#1 lore raw
Quoted 4 lines · On Fri, 21 Aug 2009 09:36:08 +0200 Jiri Slaby <[email protected]> wrote:

Fix this compilation warning on x86_64:
fs/proc/kcore.c: In function ‘kclist_add_private’:
fs/proc/kcore.c:175: warning: comparison between pointer and integer

Oh, thank you.

Quoted 23 lines
Cc KAMEZAWA Hiroyuki <[email protected]>
---
 fs/proc/kcore.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
fs/proc/kcore.c +1 -1
index aabbc3a..98fcf17 100644
@@ -172,7 +172,7 @@ kclist_add_private(unsigned long pfn, unsigned long nr_pages, void *arg)
 		ent->size = ULONG_MAX - ent->addr;
 
 	/* cut when vmalloc() area is higher than direct-map area */
-	if (VMALLOC_START > __va(0)) {
+	if (VMALLOC_START > (unsigned long)__va(0)) {
 		if (ent->addr > VMALLOC_START)
 			goto free_out;
 		if (VMALLOC_START - ent->addr < ent->size)
Signature · 1 line
1.6.3.3