aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd/ubi
diff options
context:
space:
mode:
authorArtem Bityutskiy <Artem.Bityutskiy@nokia.com>2007-12-17 06:21:07 -0500
committerArtem Bityutskiy <Artem.Bityutskiy@nokia.com>2007-12-26 12:15:15 -0500
commitc63a491d3737aec3c47c5e785d87021752ad9fa6 (patch)
tree0fc3a0dee3493d52997426a745c52ff8d2287225 /drivers/mtd/ubi
parentcae0a77125467c42f0918e78457913ee4a2f925b (diff)
UBI: add some more comments
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Diffstat (limited to 'drivers/mtd/ubi')
-rw-r--r--drivers/mtd/ubi/eba.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/mtd/ubi/eba.c b/drivers/mtd/ubi/eba.c
index b2b0f29bdc53..2ff34923e51d 100644
--- a/drivers/mtd/ubi/eba.c
+++ b/drivers/mtd/ubi/eba.c
@@ -797,7 +797,7 @@ write_error:
797/* 797/*
798 * ubi_eba_atomic_leb_change - change logical eraseblock atomically. 798 * ubi_eba_atomic_leb_change - change logical eraseblock atomically.
799 * @ubi: UBI device description object 799 * @ubi: UBI device description object
800 * @vol: volume escription object 800 * @vol: volume description object
801 * @lnum: logical eraseblock number 801 * @lnum: logical eraseblock number
802 * @buf: data to write 802 * @buf: data to write
803 * @len: how many bytes to write 803 * @len: how many bytes to write
@@ -955,6 +955,12 @@ int ubi_eba_copy_leb(struct ubi_device *ubi, int from, int to,
955 /* 955 /*
956 * We may race with volume deletion/re-size, so we have to hold 956 * We may race with volume deletion/re-size, so we have to hold
957 * @ubi->volumes_lock. 957 * @ubi->volumes_lock.
958 *
959 * Note, it is not a problem if we race with volume deletion or re-size
960 * here. If the volume is deleted or re-sized while we are moving an
961 * eraseblock which belongs to this volume, we'll end up with finding
962 * out that this LEB was unmapped at the end (see WL), and drop this
963 * PEB.
958 */ 964 */
959 spin_lock(&ubi->volumes_lock); 965 spin_lock(&ubi->volumes_lock);
960 vol = ubi->volumes[idx]; 966 vol = ubi->volumes[idx];