Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 01824853 authored by Greg Ungerer's avatar Greg Ungerer Committed by Linus Torvalds
Browse files

[PATCH] m68knommu: add 5208 ColdFire reset/reboot support



Add reset/reboot code to support the ColdFire 5208 family.
Patch originally from Matt Wadell (from code originally written by
Mike Lavender).

Signed-off-by: default avatarGreg Ungerer <gerg@uclinux.com>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 06227039
Loading
Loading
Loading
Loading
+13 −0
Original line number Original line Diff line number Diff line
@@ -312,6 +312,19 @@ cmpxchg(volatile int *p, int old, int new)
	moveb #0x80, (%a0);		\
	moveb #0x80, (%a0);		\
	");				\
	");				\
})
})
#elif defined(CONFIG_M520x)
	/*
	 * The MCF5208 has a bit (SOFTRST) in memory (Reset Control Register 
	 * RCR), that when set, resets the MCF5208.
	 */
#define HARD_RESET_NOW() 		\
({					\
	unsigned char volatile *reset;	\
	asm("move.w     #0x2700, %sr");	\
	reset = ((volatile unsigned short *)(MCF_IPSBAR + 0xA0000));	\
	while(1)			\
		*reset |= 0x80;		\
})
#else
#else
#define HARD_RESET_NOW() ({		\
#define HARD_RESET_NOW() ({		\
        asm("				\
        asm("				\