Paul Gortmaker aa6f079075 sparc: fix build fail in mm/init_64.c when NEED_MULTIPLE_NODES is off
Commit 625d693e9784f988371e69c2b41a2172c0be6c11 (linux-next)

    "sparc64: Convert over to NO_BOOTMEM."

causes the following compile failure for sparc64 allnoconfig:

  arch/sparc/mm/init_64.c:822:16: error: unused variable 'paddr'
  arch/sparc/mm/init_64.c:1759:7: error: unused variable 'node'
  arch/sparc/mm/init_64.c:809:12: error: 'memblock_nid_range' defined but not used

The paddr decl can easily be shuffled within the ifdef.  The
memblock_nid_range is just a stub function for when NEED_MULTIPLE_NODES
is off, but the only caller is within a NEED_MULTIPLE_NODES enabled
section, so we can simply delete it.

The unused "node" is slightly more interesting.  In the case of
"# CONFIG_NEED_MULTIPLE_NODES is not set" we no longer get the
definition of:

 #define NODE_DATA(nid)          (node_data[nid])

from arch/sparc/include/asm/mmzone.h - but instead we get:

 #define NODE_DATA(nid)          (&contig_page_data)

from include/linux/mmzone.h -- and since the arg is ignored,
the thing really is unused.  Rather than put in a confusing
looking __maybe_unused, simply splitting the declaration
from the assignment seemed to me to be the least offensive.

Cc: Sam Ravnborg <sam@ravnborg.org>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2012-05-09 19:58:07 -07:00
..
2012-03-28 18:30:03 +01:00
2011-11-02 16:06:58 -07:00
2012-03-20 21:48:30 +08:00
2008-05-20 00:33:44 -07:00
2012-03-28 18:30:03 +01:00
2012-03-28 18:30:03 +01:00
2011-06-07 16:06:34 -07:00
2008-05-20 00:33:44 -07:00
2011-05-25 08:39:13 -07:00
2012-03-28 18:30:03 +01:00
2008-07-17 21:38:01 -07:00
2008-05-20 00:33:44 -07:00