Title: [9804] trunk/arch/blackfin/mach-common/ints-priority.c: Blackfin: ints-priority: clean up some local vars
Revision
9804
Author
vapier
Date
2011-03-30 01:12:10 -0400 (Wed, 30 Mar 2011)

Log Message

Blackfin: ints-priority: clean up some local vars

The local ivg structs need not be exported, so mark them as static.
Further, the "num_spurious" variable is only incremented and never
actually read anywhere, so punt it.

Modified Paths

Diff

Modified: trunk/arch/blackfin/mach-common/ints-priority.c (9803 => 9804)


--- trunk/arch/blackfin/mach-common/ints-priority.c	2011-03-29 09:10:46 UTC (rev 9803)
+++ trunk/arch/blackfin/mach-common/ints-priority.c	2011-03-30 05:12:10 UTC (rev 9804)
@@ -63,22 +63,19 @@
 EXPORT_SYMBOL(bfin_irq_flags);
 #endif
 
-/* The number of spurious interrupts */
-atomic_t num_spurious;
-
 #ifdef CONFIG_PM
 unsigned long bfin_sic_iwr[3];	/* Up to 3 SIC_IWRx registers */
 unsigned vr_wakeup;
 #endif
 
-struct ivgx {
+static struct ivgx {
 	/* irq number for request_irq, available in mach-bf5xx/irq.h */
 	unsigned int irqno;
 	/* corresponding bit in the SIC_ISR register */
 	unsigned int isrflag;
 } ivg_table[NR_PERI_INTS];
 
-struct ivg_slice {
+static struct ivg_slice {
 	/* position of first irq in ivg_table for given ivg */
 	struct ivgx *ifirst;
 	struct ivgx *istop;
@@ -1333,10 +1330,8 @@
 		sic_status[2] = bfin_read_SIC_ISR2() & bfin_read_SIC_IMASK2();
 # endif
 		for (;; ivg++) {
-			if (ivg >= ivg_stop) {
-				atomic_inc(&num_spurious);
+			if (ivg >= ivg_stop)
 				return;
-			}
 			if (sic_status[(ivg->irqno - IVG7) / 32] & ivg->isrflag)
 				break;
 		}
@@ -1346,10 +1341,9 @@
 		sic_status = bfin_read_SIC_IMASK() & bfin_read_SIC_ISR();
 
 		for (;; ivg++) {
-			if (ivg >= ivg_stop) {
-				atomic_inc(&num_spurious);
+			if (ivg >= ivg_stop)
 				return;
-			} else if (sic_status & ivg->isrflag)
+			if (sic_status & ivg->isrflag)
 				break;
 		}
 #endif
@@ -1405,10 +1399,8 @@
 		sic_status[2] = bfin_read_SIC_ISR2() & bfin_read_SIC_IMASK2();
 # endif
 		for (;; ivg++) {
-			if (ivg >= ivg_stop) {
-				atomic_inc(&num_spurious);
+			if (ivg >= ivg_stop)
 				return 0;
-			}
 			if (sic_status[(ivg->irqno - IVG7) / 32] & ivg->isrflag)
 				break;
 		}
@@ -1418,10 +1410,9 @@
 		sic_status = bfin_read_SIC_IMASK() & bfin_read_SIC_ISR();
 
 		for (;; ivg++) {
-			if (ivg >= ivg_stop) {
-				atomic_inc(&num_spurious);
+			if (ivg >= ivg_stop)
 				return 0;
-			} else if (sic_status & ivg->isrflag)
+			if (sic_status & ivg->isrflag)
 				break;
 		}
 #endif
_______________________________________________
Linux-kernel-commits mailing list
[email protected]
https://blackfin.uclinux.org/mailman/listinfo/linux-kernel-commits

Reply via email to