From 58cbe2476abce8b5e3508d23bd05c2e2e8c394da Mon Sep 17 00:00:00 2001 From: Randy Dunlap Date: Tue, 15 Mar 2011 16:12:30 -0700 Subject: sched, kernel-doc: Fix runqueue_is_locked() description Fix kernel-doc warning for runqueue_is_locked(): Warning(kernel/sched.c:664): missing initial short description Signed-off-by: Randy Dunlap Cc: Linus Torvalds LKML-Reference: <20110315161230.c4e1e8e3.rdunlap@xenotime.net> Signed-off-by: Ingo Molnar --- kernel/sched.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/kernel/sched.c b/kernel/sched.c index c8e40b7005c0..58d66ea7d200 100644 --- a/kernel/sched.c +++ b/kernel/sched.c @@ -661,10 +661,9 @@ static void update_rq_clock(struct rq *rq) #endif /** - * runqueue_is_locked + * runqueue_is_locked - Returns true if the current cpu runqueue is locked * @cpu: the processor in question. * - * Returns true if the current cpu runqueue is locked. * This interface allows printk to be called with the runqueue lock * held and know whether or not it is OK to wake up the klogd. */ -- cgit v1.2.2 From 368e2119c37312f8bb2ab4d1346c46f9611805e4 Mon Sep 17 00:00:00 2001 From: Thomas Gleixner Date: Thu, 17 Mar 2011 13:29:26 +0100 Subject: cris: Fix irq conversion fallout arch/cris/arch-v10/kernel/irq.c: In function 'init_IRQ': arch/cris/arch-v10/kernel/irq.c:202:3: error: implicit declaration of function 'set_irq_desc_and_handler' Should have been set_irq_chip_and_handler() Fix it and convert to the new function names while at it. Reported-by: Peter Zijlstra Signed-off-by: Thomas Gleixner --- arch/cris/arch-v10/kernel/irq.c | 2 +- arch/cris/arch-v32/kernel/irq.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/cris/arch-v10/kernel/irq.c b/arch/cris/arch-v10/kernel/irq.c index 7328a7cf7449..907cfb5a873d 100644 --- a/arch/cris/arch-v10/kernel/irq.c +++ b/arch/cris/arch-v10/kernel/irq.c @@ -199,7 +199,7 @@ init_IRQ(void) /* Initialize IRQ handler descriptors. */ for(i = 2; i < NR_IRQS; i++) { - set_irq_desc_and_handler(i, &crisv10_irq_type, + irq_set_chip_and_handler(i, &crisv10_irq_type, handle_simple_irq); set_int_vector(i, interrupt[i]); } diff --git a/arch/cris/arch-v32/kernel/irq.c b/arch/cris/arch-v32/kernel/irq.c index 0ad9db5126c7..54ac2f79f849 100644 --- a/arch/cris/arch-v32/kernel/irq.c +++ b/arch/cris/arch-v32/kernel/irq.c @@ -451,7 +451,7 @@ init_IRQ(void) /* Point all IRQ's to bad handlers. */ for (i = FIRST_IRQ, j = 0; j < NR_IRQS; i++, j++) { - set_irq_chip_and_handler(j, &crisv32_irq_type, + irq_set_chip_and_handler(j, &crisv32_irq_type, handle_simple_irq); set_exception_vector(i, interrupt[j]); } -- cgit v1.2.2 From 6d05c80dd2115d69599368b150c3df0cf5a54c51 Mon Sep 17 00:00:00 2001 From: Thomas Gleixner Date: Thu, 17 Mar 2011 13:35:28 +0100 Subject: cris: Use accessor functions to set IRQ_PER_CPU flag Signed-off-by: Thomas Gleixner --- arch/cris/arch-v32/kernel/irq.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/cris/arch-v32/kernel/irq.c b/arch/cris/arch-v32/kernel/irq.c index 54ac2f79f849..8023176e19b2 100644 --- a/arch/cris/arch-v32/kernel/irq.c +++ b/arch/cris/arch-v32/kernel/irq.c @@ -456,11 +456,11 @@ init_IRQ(void) set_exception_vector(i, interrupt[j]); } - /* Mark Timer and IPI IRQs as CPU local */ + /* Mark Timer and IPI IRQs as CPU local */ irq_allocations[TIMER0_INTR_VECT - FIRST_IRQ].cpu = CPU_FIXED; - irq_desc[TIMER0_INTR_VECT].status |= IRQ_PER_CPU; + irq_set_status_flags(TIMER0_INTR_VECT, IRQ_PER_CPU); irq_allocations[IPI_INTR_VECT - FIRST_IRQ].cpu = CPU_FIXED; - irq_desc[IPI_INTR_VECT].status |= IRQ_PER_CPU; + irq_set_status_flags(IPI_INTR_VECT, IRQ_PER_CPU); set_exception_vector(0x00, nmi_interrupt); set_exception_vector(0x30, multiple_interrupt); -- cgit v1.2.2 From ee0401ec11bb7b83b7fa9476d0aaeabd59216062 Mon Sep 17 00:00:00 2001 From: Thomas Gleixner Date: Thu, 17 Mar 2011 13:36:57 +0100 Subject: genirq: show_interrupts: Check desc->name before printing it blindly desc->name is not required and not used by all architectures. Signed-off-by: Thomas Gleixner --- kernel/irq/proc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/kernel/irq/proc.c b/kernel/irq/proc.c index 4cc2e5ed0bec..760248de109d 100644 --- a/kernel/irq/proc.c +++ b/kernel/irq/proc.c @@ -405,7 +405,8 @@ int show_interrupts(struct seq_file *p, void *v) for_each_online_cpu(j) seq_printf(p, "%10u ", kstat_irqs_cpu(i, j)); seq_printf(p, " %8s", desc->irq_data.chip->name); - seq_printf(p, "-%-8s", desc->name); + if (desc->name) + seq_printf(p, "-%-8s", desc->name); if (action) { seq_printf(p, " %s", action->name); -- cgit v1.2.2 From 15825a5cd4adb199fd76737e8bc846154e315218 Mon Sep 17 00:00:00 2001 From: Thomas Gleixner Date: Thu, 17 Mar 2011 13:39:19 +0100 Subject: cris: Use generic show_interrupts() Signed-off-by: Thomas Gleixner Cc: Jesper Nilsson --- arch/cris/Kconfig | 1 + arch/cris/kernel/irq.c | 39 --------------------------------------- 2 files changed, 1 insertion(+), 39 deletions(-) diff --git a/arch/cris/Kconfig b/arch/cris/Kconfig index 0a7a4c11d8b1..4db5b46e1eff 100644 --- a/arch/cris/Kconfig +++ b/arch/cris/Kconfig @@ -56,6 +56,7 @@ config CRIS select HAVE_IDE select HAVE_GENERIC_HARDIRQS select GENERIC_HARDIRQS_NO_DEPRECATED + select GENERIC_IRQ_SHOW config HZ int diff --git a/arch/cris/kernel/irq.c b/arch/cris/kernel/irq.c index c346952f06dc..788eb2248916 100644 --- a/arch/cris/kernel/irq.c +++ b/arch/cris/kernel/irq.c @@ -37,45 +37,6 @@ #include -int show_interrupts(struct seq_file *p, void *v) -{ - int i = *(loff_t *) v, j; - struct irqaction * action; - unsigned long flags; - - if (i == 0) { - seq_printf(p, " "); - for_each_online_cpu(j) - seq_printf(p, "CPU%d ",j); - seq_putc(p, '\n'); - } - - if (i < NR_IRQS) { - raw_spin_lock_irqsave(&irq_desc[i].lock, flags); - action = irq_desc[i].action; - if (!action) - goto skip; - seq_printf(p, "%3d: ",i); -#ifndef CONFIG_SMP - seq_printf(p, "%10u ", kstat_irqs(i)); -#else - for_each_online_cpu(j) - seq_printf(p, "%10u ", kstat_irqs_cpu(i, j)); -#endif - seq_printf(p, " %14s", irq_desc[i].irq_data.chip->name); - seq_printf(p, " %s", action->name); - - for (action=action->next; action; action = action->next) - seq_printf(p, ", %s", action->name); - - seq_putc(p, '\n'); -skip: - raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags); - } - return 0; -} - - /* 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 -- cgit v1.2.2 From 1c389795c15d349c2c7b23baf927e16e86ca3ae8 Mon Sep 17 00:00:00 2001 From: Dan Carpenter Date: Thu, 17 Mar 2011 14:43:07 +0300 Subject: genirq: Fix incorrect unlock in __setup_irq() MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit goto out_thread is called before we take the lock. It causes a gcc warning: "kernel/irq/manage.c:858: warning: ‘flags’ may be used uninitialized in this function" [ tglx: Moved unlock before free_cpumask_var() ] Signed-off-by: Dan Carpenter LKML-Reference: <20110317114307.GJ2008@bicker> Signed-off-by: Thomas Gleixner --- kernel/irq/manage.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/irq/manage.c b/kernel/irq/manage.c index acd599a43bfb..0a2aa73e536c 100644 --- a/kernel/irq/manage.c +++ b/kernel/irq/manage.c @@ -1064,10 +1064,10 @@ mismatch: ret = -EBUSY; out_mask: + raw_spin_unlock_irqrestore(&desc->lock, flags); free_cpumask_var(mask); out_thread: - raw_spin_unlock_irqrestore(&desc->lock, flags); if (new->thread) { struct task_struct *t = new->thread; -- cgit v1.2.2