Use CPLD watchdog to reset the machine instead of buggy ep93xx one, which
sometimes get stuck...

Signed-off-by: Petr Stetiar <ynezz@true.cz>

Index: linux-2.6.22/include/asm-arm/arch-ep93xx/system.h
===================================================================
--- linux-2.6.22.orig/include/asm-arm/arch-ep93xx/system.h	2007-08-30 00:53:47.000000000 +0200
+++ linux-2.6.22/include/asm-arm/arch-ep93xx/system.h	2007-08-30 00:54:28.000000000 +0200
@@ -3,6 +3,7 @@
  */
 
 #include <asm/hardware.h>
+#include <asm/mach-types.h>
 
 static inline void arch_idle(void)
 {
@@ -15,11 +16,17 @@
 
 	local_irq_disable();
 
-	devicecfg = __raw_readl(EP93XX_SYSCON_DEVICE_CONFIG);
-	__raw_writel(0xaa, EP93XX_SYSCON_SWLOCK);
-	__raw_writel(devicecfg | 0x80000000, EP93XX_SYSCON_DEVICE_CONFIG);
-	__raw_writel(0xaa, EP93XX_SYSCON_SWLOCK);
-	__raw_writel(devicecfg & ~0x80000000, EP93XX_SYSCON_DEVICE_CONFIG);
+	if (machine_is_ts72xx()) {
+		__raw_writeb(0x5, TS72XX_WATCHDOG_FEED_PHYS_BASE);
+		__raw_writeb(0x1, TS72XX_WATCHDOG_CONTROL_PHYS_BASE);
+	} else {
+		devicecfg = __raw_readl(EP93XX_SYSCON_DEVICE_CONFIG);
+		__raw_writel(0xaa, EP93XX_SYSCON_SWLOCK);
+		__raw_writel(devicecfg | 0x80000000, EP93XX_SYSCON_DEVICE_CONFIG);
+		__raw_writel(0xaa, EP93XX_SYSCON_SWLOCK);
+		__raw_writel(devicecfg & ~0x80000000, EP93XX_SYSCON_DEVICE_CONFIG);
+	}
+
 
 	while (1)
 		;