]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/powerpc/platforms/powermac/udbg_scc.c
Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik...
[linux-2.6-omap-h63xx.git] / arch / powerpc / platforms / powermac / udbg_scc.c
index e87d53acfb61827936bb200badbc794f0f569c91..ce1a235855f7557e0f15ed061429254d9fff41d4 100644 (file)
@@ -8,7 +8,6 @@
  *      as published by the Free Software Foundation; either version
  *      2 of the License, or (at your option) any later version.
  */
-#include <linux/config.h>
 #include <linux/types.h>
 #include <asm/udbg.h>
 #include <asm/processor.h>
@@ -69,11 +68,11 @@ static unsigned char scc_inittab[] = {
 
 void udbg_scc_init(int force_scc)
 {
-       u32 *reg;
+       const u32 *reg;
        unsigned long addr;
        struct device_node *stdout = NULL, *escc = NULL, *macio = NULL;
        struct device_node *ch, *ch_def = NULL, *ch_a = NULL;
-       char *path;
+       const char *path;
        int i, x;
 
        escc = of_find_node_by_name(NULL, "escc");
@@ -82,7 +81,7 @@ void udbg_scc_init(int force_scc)
        macio = of_get_parent(escc);
        if (macio == NULL)
                goto bail;
-       path = (char *)get_property(of_chosen, "linux,stdout-path", NULL);
+       path = get_property(of_chosen, "linux,stdout-path", NULL);
        if (path != NULL)
                stdout = of_find_node_by_path(path);
        for (ch = NULL; (ch = of_get_next_child(escc, ch)) != NULL;) {
@@ -97,13 +96,13 @@ void udbg_scc_init(int force_scc)
        ch = ch_def ? ch_def : ch_a;
 
        /* Get address within mac-io ASIC */
-       reg = (u32 *)get_property(escc, "reg", NULL);
+       reg = get_property(escc, "reg", NULL);
        if (reg == NULL)
                goto bail;
        addr = reg[0];
 
        /* Get address of mac-io PCI itself */
-       reg = (u32 *)get_property(macio, "assigned-addresses", NULL);
+       reg = get_property(macio, "assigned-addresses", NULL);
        if (reg == NULL)
                goto bail;
        addr += reg[2];
@@ -116,7 +115,7 @@ void udbg_scc_init(int force_scc)
        /* Setup for 57600 8N1 */
        if (ch == ch_a)
                addr += 0x20;
-       sccc = (volatile u8 * __iomem) ioremap(addr & PAGE_MASK, PAGE_SIZE) ;
+       sccc = ioremap(addr & PAGE_MASK, PAGE_SIZE) ;
        sccc += addr & ~PAGE_MASK;
        sccd = sccc + 0x10;
 
@@ -153,7 +152,7 @@ static void udbg_real_scc_putc(char c)
                udbg_real_scc_putc('\r');
 }
 
-void udbg_init_pmac_realmode(void)
+void __init udbg_init_pmac_realmode(void)
 {
        sccc = (volatile u8 __iomem *)0x80013020ul;
        sccd = (volatile u8 __iomem *)0x80013030ul;