]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
Blackfin arch: read SYSCR on newer parts that mirror the bits of SWRST in it
authorMike Frysinger <vapier.adi@gmail.com>
Wed, 4 Feb 2009 08:49:45 +0000 (16:49 +0800)
committerBryan Wu <cooloney@kernel.org>
Wed, 4 Feb 2009 08:49:45 +0000 (16:49 +0800)
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
arch/blackfin/kernel/setup.c

index a23fec573c0a241fa51e5bf38e35183dd72c2d38..86feb4274218dcde15047d6e7d62a5a196929767 100644 (file)
@@ -826,7 +826,13 @@ void __init setup_arch(char **cmdline_p)
 
        printk(KERN_INFO "Boot Mode: %i\n", bfin_read_SYSCR() & 0xF);
 
+       /* Newer parts mirror SWRST bits in SYSCR */
+#if defined(CONFIG_BF53x) || defined(CONFIG_BF561) || \
+    defined(CONFIG_BF538) || defined(CONFIG_BF539)
        _bfin_swrst = bfin_read_SWRST();
+#else
+       _bfin_swrst = bfin_read_SYSCR();
+#endif
 
 #ifdef CONFIG_DEBUG_DOUBLEFAULT_PRINT
        bfin_write_SWRST(_bfin_swrst & ~DOUBLE_FAULT);