[PATCH] fs/inode.c warning if !HIGHMEM (was: Re: Linux 2.4.25-pre5)

From: Geert Uytterhoeven
Date: Mon Feb 02 2004 - 10:41:49 EST


On Mon, 19 Jan 2004, Geert Uytterhoeven wrote:
> On Thu, 15 Jan 2004, Marcelo Tosatti wrote:
> > Summary of changes from v2.4.25-pre4 to v2.4.25-pre5
> > ============================================
> >
> > Rik van Riel:
> > o Reclaim inodes with highmem pages when low on memory
>
> This introduces a warning when compiling fs/inode.c if CONFIG_HIGHMEM is not
> set, since in that case avg_pages is defined but not used.

And it's still there in -pre8. This patch kills the warning:

--- linux-2.4.25-pre8/fs/inode.c.orig 2004-01-24 19:55:47.000000000 +0100
+++ linux-2.4.25-pre8/fs/inode.c 2004-01-24 21:20:54.000000000 +0100
@@ -790,7 +790,10 @@
{
LIST_HEAD(list);
struct list_head *entry, *freeable = &list;
- int count, avg_pages;
+ int count;
+#ifdef CONFIG_HIGHMEM
+ int avg_pages;
+#endif
struct inode * inode;

spin_lock(&inode_lock);

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/