]> git.hungrycats.org Git - linux/commitdiff
[PATCH] sh64: Add asm-sh64/setup.h
authorPaul Mundt <lethal@linux-sh.org>
Sun, 11 Jul 2004 02:37:09 +0000 (19:37 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Sun, 11 Jul 2004 02:37:09 +0000 (19:37 -0700)
With the recent changes to init/main.c, we need an asm-sh64/setup.h.  This
pulls out the definitions from arch/sh64/kernel/setup.c and moves them to
setup.h instead.

Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/sh64/kernel/setup.c
arch/sh64/mm/init.c
include/asm-sh64/setup.h [new file with mode: 0644]

index e848957b5837368e5883449262c60b39851924a4..ce76634d640654ae60ed3242a190b01e691daa2d 100644 (file)
@@ -56,6 +56,7 @@
 #include <asm/system.h>
 #include <asm/io.h>
 #include <asm/sections.h>
+#include <asm/setup.h>
 #include <asm/smp.h>
 
 #ifdef CONFIG_VT
@@ -82,23 +83,11 @@ extern void platform_reserve(void);
 extern int sh64_cache_init(void);
 extern int sh64_tlb_init(void);
 
-#define RAMDISK_IMAGE_START_MASK       0x07FF
+#define RAMDISK_IMAGE_START_MASK       0x07FF
 #define RAMDISK_PROMPT_FLAG            0x8000
 #define RAMDISK_LOAD_FLAG              0x4000
 
-#define PARAM ((unsigned char *)empty_zero_page)
-#define MOUNT_ROOT_RDONLY (*(unsigned long *) (PARAM+0x000))
-#define RAMDISK_FLAGS (*(unsigned long *) (PARAM+0x004))
-#define ORIG_ROOT_DEV (*(unsigned long *) (PARAM+0x008))
-#define LOADER_TYPE (*(unsigned long *) (PARAM+0x00c))
-#define INITRD_START (*(unsigned long *) (PARAM+0x010))
-#define INITRD_SIZE (*(unsigned long *) (PARAM+0x014))
-
-#define COMMAND_LINE ((char *) (PARAM+256))
-#define COMMAND_LINE_SIZE 256
-
 static char command_line[COMMAND_LINE_SIZE] = { 0, };
-       char saved_command_line[COMMAND_LINE_SIZE];
 unsigned long long memory_start = CONFIG_MEMORY_START;
 unsigned long long memory_end = CONFIG_MEMORY_START + (CONFIG_MEMORY_SIZE_IN_MB * 1024 * 1024);
 
@@ -218,10 +207,10 @@ void __init setup_arch(char **cmdline_p)
        last_pfn = PFN_DOWN(memory_end);
        pages = last_pfn - first_pfn;
 
-       /*
+       /*
         * Partially used pages are not usable - thus
         * we are rounding upwards:
-        */
+        */
        start_pfn = PFN_UP(__pa(_end));
 
        /*
index 73df923048dc2b5cea3e249e34c18aea51cbd4c0..17cdeb425e0585969be125304f4dc0a1411dd8b5 100644 (file)
@@ -69,7 +69,7 @@ void show_mem(void)
 
        printk("Mem-info:\n");
        show_free_areas();
-       printk("Free swap:       %6dkB\n",nr_swap_pages<<(PAGE_SHIFT-10));
+       printk("Free swap:       %6ldkB\n",nr_swap_pages<<(PAGE_SHIFT-10));
        i = max_mapnr;
        while (i-- > 0) {
                total++;
diff --git a/include/asm-sh64/setup.h b/include/asm-sh64/setup.h
new file mode 100644 (file)
index 0000000..ebd42eb
--- /dev/null
@@ -0,0 +1,16 @@
+#ifndef __ASM_SH64_SETUP_H
+#define __ASM_SH64_SETUP_H
+
+#define PARAM ((unsigned char *)empty_zero_page)
+#define MOUNT_ROOT_RDONLY (*(unsigned long *) (PARAM+0x000))
+#define RAMDISK_FLAGS (*(unsigned long *) (PARAM+0x004))
+#define ORIG_ROOT_DEV (*(unsigned long *) (PARAM+0x008))
+#define LOADER_TYPE (*(unsigned long *) (PARAM+0x00c))
+#define INITRD_START (*(unsigned long *) (PARAM+0x010))
+#define INITRD_SIZE (*(unsigned long *) (PARAM+0x014))
+
+#define COMMAND_LINE ((char *) (PARAM+256))
+#define COMMAND_LINE_SIZE 256
+
+#endif /* __ASM_SH64_SETUP_H */
+