summaryrefslogtreecommitdiff
path: root/mm
diff options
context:
space:
mode:
authorAndi Kleen <andi@firstfloor.org>2010-08-10 00:19:03 (GMT)
committerLinus Torvalds <torvalds@linux-foundation.org>2010-08-10 03:44:58 (GMT)
commit4e60c86bd9e5a7110ed28874d0b6592186550ae8 (patch)
tree9fb60e9f49b44b293a0c0c7d9f40e1a354a22b5a /mm
parent627295e492638936e76f3d8fcb1e0a3367b88341 (diff)
downloadlinux-4e60c86bd9e5a7110ed28874d0b6592186550ae8.tar.xz
gcc-4.6: mm: fix unused but set warnings
No real bugs, just some dead code and some fixups. Signed-off-by: Andi Kleen <ak@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm')
-rw-r--r--mm/filemap.c2
-rw-r--r--mm/memory.c2
-rw-r--r--mm/slab.c2
3 files changed, 1 insertions, 5 deletions
diff --git a/mm/filemap.c b/mm/filemap.c
index 20e5642..3d4df44 100644
--- a/mm/filemap.c
+++ b/mm/filemap.c
@@ -2238,14 +2238,12 @@ static ssize_t generic_perform_write(struct file *file,
do {
struct page *page;
- pgoff_t index; /* Pagecache index for current page */
unsigned long offset; /* Offset into pagecache page */
unsigned long bytes; /* Bytes to write to page */
size_t copied; /* Bytes copied from user */
void *fsdata;
offset = (pos & (PAGE_CACHE_SIZE - 1));
- index = pos >> PAGE_CACHE_SHIFT;
bytes = min_t(unsigned long, PAGE_CACHE_SIZE - offset,
iov_iter_count(i));
diff --git a/mm/memory.c b/mm/memory.c
index bde42c6..6b0c37d 100644
--- a/mm/memory.c
+++ b/mm/memory.c
@@ -307,7 +307,6 @@ void free_pgd_range(struct mmu_gather *tlb,
{
pgd_t *pgd;
unsigned long next;
- unsigned long start;
/*
* The next few lines have given us lots of grief...
@@ -351,7 +350,6 @@ void free_pgd_range(struct mmu_gather *tlb,
if (addr > end - 1)
return;
- start = addr;
pgd = pgd_offset(tlb->mm, addr);
do {
next = pgd_addr_end(addr, end);
diff --git a/mm/slab.c b/mm/slab.c
index 736e497..88435fc 100644
--- a/mm/slab.c
+++ b/mm/slab.c
@@ -394,7 +394,7 @@ static void kmem_list3_init(struct kmem_list3 *parent)
#define STATS_DEC_ACTIVE(x) do { } while (0)
#define STATS_INC_ALLOCED(x) do { } while (0)
#define STATS_INC_GROWN(x) do { } while (0)
-#define STATS_ADD_REAPED(x,y) do { } while (0)
+#define STATS_ADD_REAPED(x,y) do { (void)(y); } while (0)
#define STATS_SET_HIGH(x) do { } while (0)
#define STATS_INC_ERR(x) do { } while (0)
#define STATS_INC_NODEALLOCS(x) do { } while (0)