[<prev] [next>] [day] [month] [year] [list]
Message-Id: <201203302105.q2UL57c5006303@farm-0012.internal.tilera.com>
Date: Thu, 29 Mar 2012 16:14:40 -0400
From: Chris Metcalf <cmetcalf@...era.com>
To: Chris Metcalf <cmetcalf@...era.com>, linux-kernel@...r.kernel.org
Subject: [PATCH] arch/tile: fix pointer cast in cacheflush.c
Pragmatically it couldn't be wrong to cast pointers to long to compare
them (since all kernel addresses are in the top half of VA space),
but it's more correct to cast to unsigned long.
Signed-off-by: Chris Metcalf <cmetcalf@...era.com>
---
arch/tile/lib/cacheflush.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/tile/lib/cacheflush.c b/arch/tile/lib/cacheflush.c
index 8928aac..6af2b97 100644
--- a/arch/tile/lib/cacheflush.c
+++ b/arch/tile/lib/cacheflush.c
@@ -109,7 +109,7 @@ void finv_buffer_remote(void *buffer, size_t size, int hfh)
/* Figure out how far back we need to go. */
base = p - (step_size * (load_count - 2));
- if ((long)base < (long)buffer)
+ if ((unsigned long)base < (unsigned long)buffer)
base = buffer;
/*
--
1.6.5.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists