cris: remove deprecated IRQF_DISABLED
authorMichael Opdenacker <michael.opdenacker@free-electrons.com>
Wed, 4 Sep 2013 05:17:40 +0000 (07:17 +0200)
committerJesper Nilsson <jespern@axis.com>
Wed, 8 Jan 2014 15:10:18 +0000 (16:10 +0100)
This patch proposes to remove the IRQF_DISABLED flag from CRIS
architecture code. It's a NOOP since 2.6.35 and it will be removed
one day.

Comments mentioning IRQF_DISABLED are also updated, knowing
that all interrupts are now "fast interrupts", their handlers
running with interrupts disabled.

Don't hesitate to let me know if you have other ways of
rephrasing the comments!

This is an update for 3.11 of a patch already sent for 3.10

Signed-off-by: Michael Opdenacker <michael.opdenacker@free-electrons.com>
Signed-off-by: Jesper Nilsson <jespern@axis.com>
14 files changed:
arch/cris/arch-v10/drivers/gpio.c
arch/cris/arch-v10/drivers/sync_serial.c
arch/cris/arch-v10/kernel/time.c
arch/cris/arch-v32/drivers/mach-a3/gpio.c
arch/cris/arch-v32/drivers/mach-fs/gpio.c
arch/cris/arch-v32/kernel/fasttimer.c
arch/cris/arch-v32/kernel/irq.c
arch/cris/arch-v32/kernel/smp.c
arch/cris/arch-v32/kernel/time.c
arch/cris/arch-v32/mach-a3/arbiter.c
arch/cris/arch-v32/mach-fs/arbiter.c
arch/cris/include/arch-v10/arch/irq.h
arch/cris/include/arch-v32/arch/irq.h
arch/cris/kernel/irq.c

index 609d5510410e06e869567268a20edf133c588853..f4374bae4fb4e632a5f81102514efa4ec1477ed0 100644 (file)
@@ -838,13 +838,13 @@ static int __init gpio_init(void)
         * in some tests.
         */
        res = request_irq(TIMER0_IRQ_NBR, gpio_poll_timer_interrupt,
-               IRQF_SHARED | IRQF_DISABLED, "gpio poll", gpio_name);
+               IRQF_SHARED, "gpio poll", gpio_name);
        if (res) {
                printk(KERN_CRIT "err: timer0 irq for gpio\n");
                return res;
        }
        res = request_irq(PA_IRQ_NBR, gpio_interrupt,
-               IRQF_SHARED | IRQF_DISABLED, "gpio PA", gpio_name);
+               IRQF_SHARED, "gpio PA", gpio_name);
        if (res)
                printk(KERN_CRIT "err: PA irq for gpio\n");
 
index a1c498d18d3184d196fa184e7bfe890c982ca53e..04d39e0ca55d0285f06e48cd15bca4224b81d192 100644 (file)
@@ -580,7 +580,7 @@ static int sync_serial_open(struct inode *inode, struct file *file)
                        if (port == &ports[0]) {
                                if (request_irq(8,
                                                manual_interrupt,
-                                               IRQF_SHARED | IRQF_DISABLED,
+                                               IRQF_SHARED,
                                                "synchronous serial manual irq",
                                                &ports[0])) {
                                        printk(KERN_CRIT "Can't alloc "
@@ -590,7 +590,7 @@ static int sync_serial_open(struct inode *inode, struct file *file)
                        } else if (port == &ports[1]) {
                                if (request_irq(8,
                                                manual_interrupt,
-                                               IRQF_SHARED | IRQF_DISABLED,
+                                               IRQF_SHARED,
                                                "synchronous serial manual irq",
                                                &ports[1])) {
                                        printk(KERN_CRIT "Can't alloc "
index fce7c541d70de8331b47ccab308a6798b9491bb5..e6a722715a8dd9038f49979b00c03061a9d1858f 100644 (file)
@@ -178,13 +178,11 @@ timer_interrupt(int irq, void *dev_id)
         return IRQ_HANDLED;
 }
 
-/* timer is IRQF_SHARED so drivers can add stuff to the timer irq chain
- * it needs to be IRQF_DISABLED to make the jiffies update work properly
- */
+/* timer is IRQF_SHARED so drivers can add stuff to the timer irq chain */
 
 static struct irqaction irq2  = {
        .handler = timer_interrupt,
-       .flags = IRQF_SHARED | IRQF_DISABLED,
+       .flags = IRQF_SHARED,
        .name = "timer",
 };
 
index 0b86deedacb97b9a0e919b79d484a35f43b456cc..74f9fe80940c73cd2d66bf9a8e9d5d23c4e5ab38 100644 (file)
@@ -978,7 +978,7 @@ static int __init gpio_init(void)
        CRIS_LED_DISK_WRITE(0);
 
        int res2 = request_irq(GIO_INTR_VECT, gpio_interrupt,
-               IRQF_SHARED | IRQF_DISABLED, "gpio", &alarmlist);
+               IRQF_SHARED, "gpio", &alarmlist);
        if (res2) {
                printk(KERN_ERR "err: irq for gpio\n");
                return res2;
index a2ac0917f1a615989243bd3c1d0dc091c7f2d552..9e54273af0ca81dd4d95d462cdf869bd1d21e0f4 100644 (file)
@@ -964,11 +964,11 @@ gpio_init(void)
         * in some tests.
         */
        if (request_irq(TIMER0_INTR_VECT, gpio_poll_timer_interrupt,
-                       IRQF_SHARED | IRQF_DISABLED, "gpio poll", &alarmlist))
+                       IRQF_SHARED, "gpio poll", &alarmlist))
                printk(KERN_ERR "timer0 irq for gpio\n");
 
        if (request_irq(GIO_INTR_VECT, gpio_pa_interrupt,
-                       IRQF_SHARED | IRQF_DISABLED, "gpio PA", &alarmlist))
+                       IRQF_SHARED, "gpio PA", &alarmlist))
                printk(KERN_ERR "PA irq for gpio\n");
 
 #ifdef CONFIG_ETRAX_VIRTUAL_GPIO
index f6644535b17e199637f810b8fcbea2fcef548b0c..b130c2c5fdd892d389debe80cd0297bb88bae32f 100644 (file)
@@ -786,7 +786,7 @@ int fast_timer_init(void)
     proc_create("fasttimer", 0, NULL, &proc_fasttimer_fops);
 #endif /* PROC_FS */
                if (request_irq(TIMER0_INTR_VECT, timer_trig_interrupt,
-                               IRQF_SHARED | IRQF_DISABLED,
+                               IRQF_SHARED,
                                "fast timer int", &fast_timer_list))
                        printk(KERN_ERR "err: fasttimer irq\n");
     fast_timer_is_init = 1;
index 5ebe6e841820ec45a5a653d66993b7b2b5952bef..25437ae2812838ccf0d5e378563588e1de9096a5 100644 (file)
@@ -331,11 +331,11 @@ extern void do_IRQ(int irq, struct pt_regs * regs);
 void
 crisv32_do_IRQ(int irq, int block, struct pt_regs* regs)
 {
-       /* Interrupts that may not be moved to another CPU and
-         * are IRQF_DISABLED may skip blocking. This is currently
-         * only valid for the timer IRQ and the IPI and is used
-         * for the timer interrupt to avoid watchdog starvation.
-         */
+       /* Interrupts that may not be moved to another CPU may
+        * skip blocking. This is currently only valid for the
+        * timer IRQ and the IPI and is used for the timer
+        * interrupt to avoid watchdog starvation.
+        */
        if (!block) {
                do_IRQ(irq, regs);
                return;
index fe8e6039db2a04aa3c133385322fe6573b7b2b11..0698582467ca773c3cf704690fc9b105610b4ab0 100644 (file)
@@ -64,7 +64,7 @@ static irqreturn_t crisv32_ipi_interrupt(int irq, void *dev_id);
 static int send_ipi(int vector, int wait, cpumask_t cpu_mask);
 static struct irqaction irq_ipi  = {
        .handler = crisv32_ipi_interrupt,
-       .flags = IRQF_DISABLED,
+       .flags = 0,
        .name = "ipi",
 };
 
index 8c4b45efd7b6712f8dc13da94c55bc8ee51ca369..ee66866538f891a7ff574efd4b82d836b4b3f894 100644 (file)
@@ -216,12 +216,10 @@ static inline irqreturn_t timer_interrupt(int irq, void *dev_id)
         return IRQ_HANDLED;
 }
 
-/* Timer is IRQF_SHARED so drivers can add stuff to the timer irq chain.
- * It needs to be IRQF_DISABLED to make the jiffies update work properly.
- */
+/* Timer is IRQF_SHARED so drivers can add stuff to the timer irq chain. */
 static struct irqaction irq_timer = {
        .handler = timer_interrupt,
-       .flags = IRQF_SHARED | IRQF_DISABLED,
+       .flags = IRQF_SHARED,
        .name = "timer"
 };
 
index 15f5c9de26399893e78d8f82e7783aa1cb8b0757..ab5c421a4de86fb3af3614e01ec5bd8ebdb5af8d 100644 (file)
@@ -256,11 +256,11 @@ static void crisv32_arbiter_init(void)
        crisv32_arbiter_config(1, EXT_REGION, 0);
 
        if (request_irq(MEMARB_FOO_INTR_VECT, crisv32_foo_arbiter_irq,
-                       IRQF_DISABLED, "arbiter", NULL))
+                       0, "arbiter", NULL))
                printk(KERN_ERR "Couldn't allocate arbiter IRQ\n");
 
        if (request_irq(MEMARB_BAR_INTR_VECT, crisv32_bar_arbiter_irq,
-                       IRQF_DISABLED, "arbiter", NULL))
+                       0, "arbiter", NULL))
                printk(KERN_ERR "Couldn't allocate arbiter IRQ\n");
 
 #ifndef CONFIG_ETRAX_KGDB
index 3f8ebb5c14771300e49106f78dc58acaba67d037..c97f4d8120f9e43747b120fd8fc8ef814c0060ed 100644 (file)
@@ -184,7 +184,7 @@ static void crisv32_arbiter_init(void)
        crisv32_arbiter_config(EXT_REGION, 0);
        crisv32_arbiter_config(INT_REGION, 0);
 
-       if (request_irq(MEMARB_INTR_VECT, crisv32_arbiter_irq, IRQF_DISABLED,
+       if (request_irq(MEMARB_INTR_VECT, crisv32_arbiter_irq, 0,
                        "arbiter", NULL))
                printk(KERN_ERR "Couldn't allocate arbiter IRQ\n");
 
index ca2675ae08ed95d1c3de56ad0a507af390b348e3..6aecb835037d3cf2c02da7c637f7653ce43cd4a5 100644 (file)
@@ -141,9 +141,9 @@ __asm__ ( \
  * handler is run and it prioritizes the timer interrupt. However if we had BLOCK'ed
  * it here, we would not get the multiple_irq at all.
  *
- * The non-blocking here is based on the knowledge that the timer interrupt is 
- * registered as a fast interrupt (IRQF_DISABLED) so that we _know_ there will not
- * be an sti() before the timer irq handler is run to acknowledge the interrupt.
+ * The non-blocking here is based on the knowledge that the timer interrupt runs
+ * with interrupts disabled, and therefore there will not be an sti() before the
+ * timer irq handler is run to acknowledge the interrupt.
  */
 
 #define BUILD_TIMER_IRQ(nr,mask) \
index fe3cdd22bed4590315268c156e28076c26cff238..0c1b4d3a34e749b222c1d0ec0af3a56a4b80b952 100644 (file)
@@ -102,9 +102,9 @@ __asm__ (                           \
  * multiple_irq handler is run and it prioritizes the timer interrupt. However
  * if we had BLOCK'edit here, we would not get the multiple_irq at all.
  *
- * The non-blocking here is based on the knowledge that the timer interrupt is
- * registered as a fast interrupt (IRQF_DISABLED) so that we _know_ there will not
- * be an sti() before the timer irq handler is run to acknowledge the interrupt.
+ * The non-blocking here is based on the knowledge that the timer interrupt runs
+ * with interrupts disabled, and therefore there will not be an sti() before the
+ * timer irq handler is run to acknowledge the interrupt.
  */
 #define BUILD_TIMER_IRQ(nr, mask)      \
 void IRQ_NAME(nr);                     \
index d36836dbbc0722758f9e116537c5e413a6e4871a..dd0be5de55d5b6ea27a2410b984e3bba0e5b9e72 100644 (file)
@@ -40,9 +40,6 @@
 
 /* called by the assembler IRQ entry functions defined in irq.h
  * to dispatch the interrupts to registered handlers
- * interrupts are disabled upon entry - depending on if the
- * interrupt was registered with IRQF_DISABLED or not, interrupts
- * are re-enabled or not.
  */
 
 asmlinkage void do_IRQ(int irq, struct pt_regs * regs)