]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/md/raid1.c
Merge tag 'xfs-4.12-fixes-4' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux
[karo-tx-linux.git] / drivers / md / raid1.c
index af5056d568788a53f6c3a2456a353cba3bbfe35a..e1a7e3d4c5e4f17d0dedb4f171ad3bd47ff70022 100644 (file)
@@ -3063,6 +3063,8 @@ static int raid1_run(struct mddev *mddev)
                        mdname(mddev));
                return -EIO;
        }
+       if (mddev_init_writes_pending(mddev) < 0)
+               return -ENOMEM;
        /*
         * copy the already verified devices into our private RAID1
         * bookkeeping area. [whatever we allocate in run(),