Update of /cvsroot/linuxsh/linux/arch/sh/boards/renesas/r7780rp
In directory sc8-pr-cvs6.sourceforge.net:/tmp/cvs-serv6166/arch/sh/boards/renesas/r7780rp
Modified Files:
setup.c
Log Message:
Some more machvec overhauling and setup code cleanup. Kill off
get_system_type() and platform_setup(), we can do these both through the
machvec. While we're add it, kill off more useless mach.c's and drop some
legacy cruft from setup.c.
Index: setup.c
===================================================================
RCS file: /cvsroot/linuxsh/linux/arch/sh/boards/renesas/r7780rp/setup.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- setup.c 6 Jul 2006 08:19:31 -0000 1.3
+++ setup.c 7 Aug 2006 06:27:25 -0000 1.4
@@ -20,41 +20,6 @@
extern void heartbeat_r7780rp(void);
extern void init_r7780rp_IRQ(void);
-/*
- * The Machine Vector
- */
-struct sh_machine_vector mv_r7780rp __initmv = {
- .mv_nr_irqs = 109,
-
- .mv_inb = r7780rp_inb,
- .mv_inw = r7780rp_inw,
- .mv_inl = r7780rp_inl,
- .mv_outb = r7780rp_outb,
- .mv_outw = r7780rp_outw,
- .mv_outl = r7780rp_outl,
-
- .mv_inb_p = r7780rp_inb_p,
- .mv_inw_p = r7780rp_inw,
- .mv_inl_p = r7780rp_inl,
- .mv_outb_p = r7780rp_outb_p,
- .mv_outw_p = r7780rp_outw,
- .mv_outl_p = r7780rp_outl,
-
- .mv_insb = r7780rp_insb,
- .mv_insw = r7780rp_insw,
- .mv_insl = r7780rp_insl,
- .mv_outsb = r7780rp_outsb,
- .mv_outsw = r7780rp_outsw,
- .mv_outsl = r7780rp_outsl,
-
- .mv_ioport_map = r7780rp_ioport_map,
- .mv_init_irq = init_r7780rp_IRQ,
-#ifdef CONFIG_HEARTBEAT
- .mv_heartbeat = heartbeat_r7780rp,
-#endif
-};
-ALIAS_MV(r7780rp)
-
static struct resource m66596_usb_host_resources[] = {
[0] = {
.start = 0xa4800000,
@@ -88,7 +53,6 @@
return platform_add_devices(r7780rp_devices,
ARRAY_SIZE(r7780rp_devices));
}
-__initcall(r7780rp_devices_setup);
/*
* Platform specific clocks
@@ -117,9 +81,8 @@
&ivdr_clk,
};
-const char *get_system_type(void)
+static const char *r7780rp_system_type(void)
{
- return "Highlander R7780RP-1";
}
static void r7780rp_power_off(void)
@@ -132,11 +95,13 @@
/*
* Initialize the board
*/
-void __init platform_setup(void)
+static void __init r7780rp_setup(char **cmdline_p)
{
u16 ver = ctrl_inw(PA_VERREG);
int i;
+ device_initcall(r7780rp_devices_setup);
+
printk(KERN_INFO "Renesas Solutions Highlander R7780RP-1 support.\n");
printk(KERN_INFO "Board version: %d (revision %d), "
@@ -162,3 +127,41 @@
pm_power_off = r7780rp_power_off;
}
+
+/*
+ * The Machine Vector
+ */
+struct sh_machine_vector mv_r7780rp __initmv = {
+ .mv_name = "Highlander R7780RP-1",
+ .mv_setup = r7780rp_setup,
+
+ .mv_nr_irqs = 109,
+
+ .mv_inb = r7780rp_inb,
+ .mv_inw = r7780rp_inw,
+ .mv_inl = r7780rp_inl,
+ .mv_outb = r7780rp_outb,
+ .mv_outw = r7780rp_outw,
+ .mv_outl = r7780rp_outl,
+
+ .mv_inb_p = r7780rp_inb_p,
+ .mv_inw_p = r7780rp_inw,
+ .mv_inl_p = r7780rp_inl,
+ .mv_outb_p = r7780rp_outb_p,
+ .mv_outw_p = r7780rp_outw,
+ .mv_outl_p = r7780rp_outl,
+
+ .mv_insb = r7780rp_insb,
+ .mv_insw = r7780rp_insw,
+ .mv_insl = r7780rp_insl,
+ .mv_outsb = r7780rp_outsb,
+ .mv_outsw = r7780rp_outsw,
+ .mv_outsl = r7780rp_outsl,
+
+ .mv_ioport_map = r7780rp_ioport_map,
+ .mv_init_irq = init_r7780rp_IRQ,
+#ifdef CONFIG_HEARTBEAT
+ .mv_heartbeat = heartbeat_r7780rp,
+#endif
+};
+ALIAS_MV(r7780rp)
|