UBIFS: switch to RO mode after synchronizing
authorArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Wed, 4 Aug 2010 07:14:47 +0000 (10:14 +0300)
committerArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Mon, 30 Aug 2010 07:19:06 +0000 (10:19 +0300)
In 'ubifs_garbage_collect()' on error path, we first switch to R/O mode, and
then synchronize write-buffers (to make sure no data are lost). But the GC
write-buffer synchronization will fail, because we are already in R/O mode.
This patch re-orders this and makes sure we first synchronize the write-buffer,
and then switch to R/O mode.

Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>

No differences found