s390/cio: fix unlocked access of global bitmap
authorSebastian Ott <sebott@linux.vnet.ibm.com>
Thu, 29 Aug 2013 18:31:06 +0000 (20:31 +0200)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Fri, 30 Aug 2013 06:57:22 +0000 (08:57 +0200)
Access to the slow_subchannel_set has to be secured via the
slow_subchannel_lock.

Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
drivers/s390/cio/css.c

index 4eb2a54..8c2cb87 100644 (file)
@@ -546,7 +546,9 @@ static int slow_eval_unknown_fn(struct subchannel_id schid, void *data)
                case -ENOMEM:
                case -EIO:
                        /* These should abort looping */
+                       spin_lock_irq(&slow_subchannel_lock);
                        idset_sch_del_subseq(slow_subchannel_set, schid);
+                       spin_unlock_irq(&slow_subchannel_lock);
                        break;
                default:
                        rc = 0;