Skip to content

Commit

Permalink
ARM: restart: sa1100: use new restart hook
Browse files Browse the repository at this point in the history
Hook these platforms restart code into the new restart hook rather
than using arch_reset().

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Russell King committed Jan 5, 2012
1 parent 1f34f0e commit d9ca583
Show file tree
Hide file tree
Showing 16 changed files with 25 additions and 9 deletions.
1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/assabet.c
Original file line number Diff line number Diff line change
Expand Up @@ -455,4 +455,5 @@ MACHINE_START(ASSABET, "Intel-Assabet")
#ifdef CONFIG_SA1111
.dma_zone_size = SZ_1M,
#endif
.restart = sa11x0_restart,
MACHINE_END
1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/badge4.c
Original file line number Diff line number Diff line change
Expand Up @@ -309,4 +309,5 @@ MACHINE_START(BADGE4, "Hewlett-Packard Laboratories BadgePAD 4")
#ifdef CONFIG_SA1111
.dma_zone_size = SZ_1M,
#endif
.restart = sa11x0_restart,
MACHINE_END
1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/cerf.c
Original file line number Diff line number Diff line change
Expand Up @@ -139,4 +139,5 @@ MACHINE_START(CERF, "Intrinsyc CerfBoard/CerfCube")
.init_irq = cerf_init_irq,
.timer = &sa1100_timer,
.init_machine = cerf_init,
.restart = sa11x0_restart,
MACHINE_END
1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/collie.c
Original file line number Diff line number Diff line change
Expand Up @@ -387,4 +387,5 @@ MACHINE_START(COLLIE, "Sharp-Collie")
.init_irq = sa1100_init_irq,
.timer = &sa1100_timer,
.init_machine = collie_init,
.restart = sa11x0_restart,
MACHINE_END
11 changes: 11 additions & 0 deletions arch/arm/mach-sa1100/generic.c
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,17 @@ static void sa1100_power_off(void)
PMCR = PMCR_SF;
}

void sa11x0_restart(char mode, const char *cmd)
{
if (mode == 's') {
/* Jump into ROM at address 0 */
soft_restart(0);
} else {
/* Use on-chip reset capability */
RSRR = RSRR_SWR;
}
}

static void sa11x0_register_device(struct platform_device *dev, void *data)
{
int err;
Expand Down
1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/generic.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ extern struct sys_timer sa1100_timer;
extern void __init sa1100_map_io(void);
extern void __init sa1100_init_irq(void);
extern void __init sa1100_init_gpio(void);
extern void sa11x0_restart(char, const char *);

#define SET_BANK(__nr,__start,__size) \
mi->bank[__nr].start = (__start), \
Expand Down
1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/h3100.c
Original file line number Diff line number Diff line change
Expand Up @@ -89,5 +89,6 @@ MACHINE_START(H3100, "Compaq iPAQ H3100")
.init_irq = sa1100_init_irq,
.timer = &sa1100_timer,
.init_machine = h3100_mach_init,
.restart = sa11x0_restart,
MACHINE_END

1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/h3600.c
Original file line number Diff line number Diff line change
Expand Up @@ -130,5 +130,6 @@ MACHINE_START(H3600, "Compaq iPAQ H3600")
.init_irq = sa1100_init_irq,
.timer = &sa1100_timer,
.init_machine = h3600_mach_init,
.restart = sa11x0_restart,
MACHINE_END

1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/hackkit.c
Original file line number Diff line number Diff line change
Expand Up @@ -200,4 +200,5 @@ MACHINE_START(HACKKIT, "HackKit Cpu Board")
.init_irq = sa1100_init_irq,
.timer = &sa1100_timer,
.init_machine = hackkit_init,
.restart = sa11x0_restart,
MACHINE_END
9 changes: 0 additions & 9 deletions arch/arm/mach-sa1100/include/mach/system.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,11 @@
*
* Copyright (c) 1999 Nicolas Pitre <nico@fluxnic.net>
*/
#include <mach/hardware.h>

static inline void arch_idle(void)
{
cpu_do_idle();
}

static inline void arch_reset(char mode, const char *cmd)
{
if (mode == 's') {
/* Jump into ROM at address 0 */
soft_restart(0);
} else {
/* Use on-chip reset capability */
RSRR = RSRR_SWR;
}
}
1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/jornada720.c
Original file line number Diff line number Diff line change
Expand Up @@ -373,4 +373,5 @@ MACHINE_START(JORNADA720, "HP Jornada 720")
#ifdef CONFIG_SA1111
.dma_zone_size = SZ_1M,
#endif
.restart = sa11x0_restart,
MACHINE_END
1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/lart.c
Original file line number Diff line number Diff line change
Expand Up @@ -66,4 +66,5 @@ MACHINE_START(LART, "LART")
.init_irq = sa1100_init_irq,
.init_machine = lart_init,
.timer = &sa1100_timer,
.restart = sa11x0_restart,
MACHINE_END
1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/nanoengine.c
Original file line number Diff line number Diff line change
Expand Up @@ -116,4 +116,5 @@ MACHINE_START(NANOENGINE, "BSE nanoEngine")
.init_irq = sa1100_init_irq,
.timer = &sa1100_timer,
.init_machine = nanoengine_init,
.restart = sa11x0_restart,
MACHINE_END
1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/pleb.c
Original file line number Diff line number Diff line change
Expand Up @@ -150,4 +150,5 @@ MACHINE_START(PLEB, "PLEB")
.init_irq = sa1100_init_irq,
.timer = &sa1100_timer,
.init_machine = pleb_init,
.restart = sa11x0_restart,
MACHINE_END
1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/shannon.c
Original file line number Diff line number Diff line change
Expand Up @@ -87,4 +87,5 @@ MACHINE_START(SHANNON, "Shannon (AKA: Tuxscreen)")
.init_irq = sa1100_init_irq,
.timer = &sa1100_timer,
.init_machine = shannon_init,
.restart = sa11x0_restart,
MACHINE_END
1 change: 1 addition & 0 deletions arch/arm/mach-sa1100/simpad.c
Original file line number Diff line number Diff line change
Expand Up @@ -396,4 +396,5 @@ MACHINE_START(SIMPAD, "Simpad")
.map_io = simpad_map_io,
.init_irq = sa1100_init_irq,
.timer = &sa1100_timer,
.restart = sa11x0_restart,
MACHINE_END

0 comments on commit d9ca583

Please sign in to comment.