UBI: fix deadlock
authorArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Thu, 4 Dec 2008 18:52:44 +0000 (20:52 +0200)
committerGrazvydas Ignotas <notasas@gmail.com>
Fri, 17 Jul 2009 13:04:10 +0000 (16:04 +0300)
commitab4a9e35a340c3ae7a0f5e79da233250bb11cc41
treedb0e50998e2d347e36fd5fd2af55a28552e58b21
parent1190143d1c105ab44e13b4836ec217b39c7a3e3f
UBI: fix deadlock

We cannot call 'ubi_wl_get_peb()' with @ubi->buf_mutex locked,
because 'ubi_wl_get_peb()' may force erasure, which, in turn,
may call 'torture_peb()' which also locks the @ubi->buf_mutex
and deadlocks.

Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
drivers/mtd/ubi/eba.c