Title: [6542] trunk/arch/blackfin/kernel/early_printk.c: use a for loop to program EVTs as gcc will turn it into a hardware loop -- much faster and smaller
Revision
6542
Author
vapier
Date
2009-06-02 19:33:31 -0500 (Tue, 02 Jun 2009)

Log Message

use a for loop to program EVTs as gcc will turn it into a hardware loop -- much faster and smaller

Modified Paths

Diff

Modified: trunk/arch/blackfin/kernel/early_printk.c (6541 => 6542)


--- trunk/arch/blackfin/kernel/early_printk.c	2009-06-02 23:15:21 UTC (rev 6541)
+++ trunk/arch/blackfin/kernel/early_printk.c	2009-06-03 00:33:31 UTC (rev 6542)
@@ -178,25 +178,15 @@
 
 asmlinkage void __init init_early_exception_vectors(void)
 {
+	u32 evt;
 	SSYNC();
 
 	/* cannot program in software:
 	 * evt0 - emulation (jtag)
 	 * evt1 - reset
 	 */
-	bfin_write_EVT2(early_trap);
-	bfin_write_EVT3(early_trap);
-	bfin_write_EVT5(early_trap);
-	bfin_write_EVT6(early_trap);
-	bfin_write_EVT7(early_trap);
-	bfin_write_EVT8(early_trap);
-	bfin_write_EVT9(early_trap);
-	bfin_write_EVT10(early_trap);
-	bfin_write_EVT11(early_trap);
-	bfin_write_EVT12(early_trap);
-	bfin_write_EVT13(early_trap);
-	bfin_write_EVT14(early_trap);
-	bfin_write_EVT15(early_trap);
+	for (evt = EVT2; evt <= EVT15; evt += 4)
+		bfin_write32(evt, early_trap);
 	CSYNC();
 
 	/* Set all the return from interrupt, exception, NMI to a known place
_______________________________________________
Linux-kernel-commits mailing list
[email protected]
https://blackfin.uclinux.org/mailman/listinfo/linux-kernel-commits

Reply via email to