Merge branch 'modsplit-Oct31_2011' of git://git.kernel.org/pub/scm/linux/kernel/git...
[pandora-kernel.git] / arch / powerpc / mm / mem.c
index ad9cf49..16da595 100644 (file)
@@ -17,7 +17,7 @@
  *
  */
 
-#include <linux/module.h>
+#include <linux/export.h>
 #include <linux/sched.h>
 #include <linux/kernel.h>
 #include <linux/errno.h>
@@ -123,7 +123,8 @@ int arch_add_memory(int nid, u64 start, u64 size)
        pgdata = NODE_DATA(nid);
 
        start = (unsigned long)__va(start);
-       create_section_mapping(start, start + size);
+       if (create_section_mapping(start, start + size))
+               return -EINVAL;
 
        /* this should work for most non-highmem platforms */
        zone = pgdata->node_zones;