]> git.karo-electronics.de Git - linux-beck.git/commitdiff
md/r5cache: enable IRQs on error path
authorDan Carpenter <dan.carpenter@oracle.com>
Thu, 24 Nov 2016 11:13:04 +0000 (14:13 +0300)
committerShaohua Li <shli@fb.com>
Mon, 28 Nov 2016 05:38:08 +0000 (21:38 -0800)
We need to re-enable the IRQs here before returning.

Fixes: a39f7afde358 ("md/r5cache: write-out phase and reclaim support")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Shaohua Li <shli@fb.com>
drivers/md/raid5-cache.c

index 5d3d238921e8c3cc3debc4ae925fd78fef80ec37..874749dc7648a7162c48c3cefabf34a5ed4575ce 100644 (file)
@@ -1029,7 +1029,7 @@ static sector_t r5c_calculate_new_cp(struct r5conf *conf)
        spin_lock_irqsave(&log->stripe_in_journal_lock, flags);
        if (list_empty(&conf->log->stripe_in_journal_list)) {
                /* all stripes flushed */
-               spin_unlock(&log->stripe_in_journal_lock);
+               spin_unlock_irqrestore(&log->stripe_in_journal_lock, flags);
                return log->next_checkpoint;
        }
        sh = list_first_entry(&conf->log->stripe_in_journal_list,