From 16f2c5261e80dded0836ba8e4b88ade005302c0b Mon Sep 17 00:00:00 2001 From: Artem Bityutskiy Date: Thu, 17 May 2012 15:31:31 +0300 Subject: [PATCH] --- yaml --- r: 305174 b: refs/heads/master c: 3561188ac29580bdc0e8db3cf3c029b87cf2c6cd h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/mtd/ubi/scan.c | 9 ++++----- trunk/drivers/mtd/ubi/scan.h | 5 ++--- trunk/drivers/mtd/ubi/vtbl.c | 7 +++---- 4 files changed, 10 insertions(+), 13 deletions(-) diff --git a/[refs] b/[refs] index e68328a5f287..ea12d0e33734 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: ee663d929213c9f7e55c45229e9a01eeb8335b50 +refs/heads/master: 3561188ac29580bdc0e8db3cf3c029b87cf2c6cd diff --git a/trunk/drivers/mtd/ubi/scan.c b/trunk/drivers/mtd/ubi/scan.c index 06151fde2cc7..366506253502 100644 --- a/trunk/drivers/mtd/ubi/scan.c +++ b/trunk/drivers/mtd/ubi/scan.c @@ -425,7 +425,7 @@ static int compare_lebs(struct ubi_device *ubi, const struct ubi_ainf_peb *aeb, } /** - * ubi_scan_add_used - add physical eraseblock to the attaching information. + * ubi_add_to_av - add physical eraseblock to the attaching information. * @ubi: UBI device description object * @ai: attaching information * @pnum: the physical eraseblock number @@ -440,9 +440,8 @@ static int compare_lebs(struct ubi_device *ubi, const struct ubi_ainf_peb *aeb, * to be picked, while the older one has to be dropped. This function returns * zero in case of success and a negative error code in case of failure. */ -int ubi_scan_add_used(struct ubi_device *ubi, struct ubi_attach_info *ai, - int pnum, int ec, const struct ubi_vid_hdr *vid_hdr, - int bitflips) +int ubi_add_to_av(struct ubi_device *ubi, struct ubi_attach_info *ai, int pnum, + int ec, const struct ubi_vid_hdr *vid_hdr, int bitflips) { int err, vol_id, lnum; unsigned long long sqnum; @@ -1016,7 +1015,7 @@ static int process_eb(struct ubi_device *ubi, struct ubi_attach_info *ai, if (ec_err) ubi_warn("valid VID header but corrupted EC header at PEB %d", pnum); - err = ubi_scan_add_used(ubi, ai, pnum, ec, vidh, bitflips); + err = ubi_add_to_av(ubi, ai, pnum, ec, vidh, bitflips); if (err) return err; diff --git a/trunk/drivers/mtd/ubi/scan.h b/trunk/drivers/mtd/ubi/scan.h index ef6e903be8e0..5a9ecc0abdd2 100644 --- a/trunk/drivers/mtd/ubi/scan.h +++ b/trunk/drivers/mtd/ubi/scan.h @@ -157,9 +157,8 @@ static inline void ubi_scan_move_to_list(struct ubi_ainf_volume *av, list_add_tail(&aeb->u.list, list); } -int ubi_scan_add_used(struct ubi_device *ubi, struct ubi_attach_info *ai, - int pnum, int ec, const struct ubi_vid_hdr *vid_hdr, - int bitflips); +int ubi_add_to_av(struct ubi_device *ubi, struct ubi_attach_info *ai, int pnum, + int ec, const struct ubi_vid_hdr *vid_hdr, int bitflips); struct ubi_ainf_volume *ubi_scan_find_av(const struct ubi_attach_info *ai, int vol_id); void ubi_scan_rm_volume(struct ubi_attach_info *ai, struct ubi_ainf_volume *av); diff --git a/trunk/drivers/mtd/ubi/vtbl.c b/trunk/drivers/mtd/ubi/vtbl.c index 0ea105b1a68b..5decd587188b 100644 --- a/trunk/drivers/mtd/ubi/vtbl.c +++ b/trunk/drivers/mtd/ubi/vtbl.c @@ -338,10 +338,9 @@ static int create_vtbl(struct ubi_device *ubi, struct ubi_attach_info *ai, /* * And add it to the attaching information. Don't delete the old version - * of this LEB as it will be deleted and freed in 'ubi_scan_add_used()'. + * of this LEB as it will be deleted and freed in 'ubi_add_to_av()'. */ - err = ubi_scan_add_used(ubi, ai, new_aeb->pnum, new_aeb->ec, - vid_hdr, 0); + err = ubi_add_to_av(ubi, ai, new_aeb->pnum, new_aeb->ec, vid_hdr, 0); kfree(new_aeb); ubi_free_vid_hdr(ubi, vid_hdr); return err; @@ -428,7 +427,7 @@ static struct ubi_vtbl_record *process_lvol(struct ubi_device *ubi, * aeb->scrub). If the data is not OK, the contents of * the PEB will be recovered from the second copy, and * aeb->scrub will be cleared in - * 'ubi_scan_add_used()'. + * 'ubi_add_to_av()'. */ aeb->scrub = 1; else if (err)