X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=fs%2Fubifs%2Fjournal.c;h=914f1bd89e571f2df8ce99d053f718ad3cc29dbd;hb=06d362931a530e0d48c1a9554a752da4ed240f0b;hp=d321baeca68db65cb0bcce2fcd38ead5ee4e2e65;hpb=fb66ebd88471cd2cc1205536dfc781b2f4c1d6b5;p=pandora-kernel.git diff --git a/fs/ubifs/journal.c b/fs/ubifs/journal.c index d321baeca68d..914f1bd89e57 100644 --- a/fs/ubifs/journal.c +++ b/fs/ubifs/journal.c @@ -122,11 +122,12 @@ static int reserve_space(struct ubifs_info *c, int jhead, int len) * better to try to allocate space at the ends of eraseblocks. This is * what the squeeze parameter does. */ + ubifs_assert(!c->ro_media && !c->ro_mount); squeeze = (jhead == BASEHD); again: mutex_lock_nested(&wbuf->io_mutex, wbuf->jhead); - if (c->ro_media) { + if (c->ro_error) { err = -EROFS; goto out_unlock; }