Commit 1c389795c15d349c2c7b23baf927e16e86ca3ae8
Committed by
Thomas Gleixner
1 parent
15825a5cd4
Exists in
master
and in
39 other branches
genirq: Fix incorrect unlock in __setup_irq()
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 <error27@gmail.com> LKML-Reference: <20110317114307.GJ2008@bicker> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff
kernel/irq/manage.c
... | ... | @@ -1064,10 +1064,10 @@ |
1064 | 1064 | ret = -EBUSY; |
1065 | 1065 | |
1066 | 1066 | out_mask: |
1067 | + raw_spin_unlock_irqrestore(&desc->lock, flags); | |
1067 | 1068 | free_cpumask_var(mask); |
1068 | 1069 | |
1069 | 1070 | out_thread: |
1070 | - raw_spin_unlock_irqrestore(&desc->lock, flags); | |
1071 | 1071 | if (new->thread) { |
1072 | 1072 | struct task_struct *t = new->thread; |
1073 | 1073 |