Missing scrub when there is a bit-flip
Subsystems (2)
PATCH 1/1 Missing scrub when there is a bit-flip
In reply to a message not in the archiveUnder some cases, when scrubbing the PEB if we didnot get the lock on the PEB it fails to scrub. Add that PEB again to the scrub list
--- drivers/mtd/ubi/eba.c | 2 +- drivers/mtd/ubi/ubi.h | 3 +++ drivers/mtd/ubi/wl.c | 5 ++++- 3 files changed, 8 insertions(+), 2 deletions(-)
drivers/mtd/ubi/eba.c +1 -1
@@ -1033,7 +1033,7 @@ int ubi_eba_copy_leb(struct ubi_device *ubi, int from, int to, err =leb_write_trylock (ubi, vol_id, lnum);if (err) {dbg_wl ("contention on LEB %d:%d, cancel" , vol_id, lnum); -return MOVE_CANCEL_RACE ; +return MOVE_RETRY ; }/*
drivers/mtd/ubi/ubi.h +3 -0
@@ -120,6 +120,8 @@ enum {* PEB * MOVE_CANCEL_BITFLIPS: canceled because a bit-flip was detected in the * target PEB +* MOVE_RETRY: Retry scrubbing the given PEB, as we didnot got lock last-time on +* it */ enum {MOVE_CANCEL_RACE =1 ,
@@ -127,6 +129,7 @@ enum {MOVE_TARGET_RD_ERR ,MOVE_TARGET_WR_ERR ,MOVE_CANCEL_BITFLIPS , + MOVE_RETRY, };/**
drivers/mtd/ubi/wl.c +4 -1
@@ -795,7 +795,10 @@ static int wear_leveling_worker(struct ubi_device *ubi, struct ubi_work *wrk, protect =1 ; goto out_not_moved; } - +if (err ==MOVE_RETRY ) { + scrubbing =1 ; + goto out_not_moved; + }if (err ==MOVE_CANCEL_BITFLIPS || err ==MOVE_TARGET_WR_ERR || err ==MOVE_TARGET_RD_ERR ) {/*
Signature · 1 line
1.7.0.4
Quoted 4 lines · Bhavesh Parekh
Under some cases, when scrubbing the PEB if we didnot get the lock on the PEB it fails to scrub. Add that PEB again to the scrub list
Signed-off-by Bhavesh Parekh <[email protected]>
I think we need to send it to -stable as well. Could you please confirm that you verified that this patch solves the issue you reported - I ask this to make double sure we are sending a good patch to the stable tree.
Thanks!
Signature · 2 lines
Best Regards, Artem Bityutskiy
Artem Bityutskiy
AppliedQuoted 4 lines · Bhavesh Parekh
Under some cases, when scrubbing the PEB if we didnot get the lock on the PEB it fails to scrub. Add that PEB again to the scrub list
Signed-off-by Bhavesh Parekh <[email protected]>
Pushed to ubi-2.6.git with minor amendments, but please, do confirm that you verify that this patch fixes the issue you described.
Thanks!
Signature · 2 lines
Best Regards, Artem Bityutskiy
Artem,
Currently we have K36 setup with most of the critical ubi fixes in it. Verified that this patch fixes the mentioned issue. Also we have K39 tree and I am planning to verify the this issue in that tree as well after porting the change and fixes from the ubi tree.
Thanks!
Bhavesh
nvpublic
Quoted 26 lines
-----Original Message-----
From: Artem Bityutskiy [mailto:[email protected]]
Sent: Sunday, December 04, 2011 7:40 PM
To: Bhavesh Parekh
Cc: [email protected]
Subject: Re: [PATCH] [MTD:UBI] Missing scrub when there is a bit-flip* PGP Signed by an unknown key
Quoted 4 lines · Bhavesh Parekh
Under some cases, when scrubbing the PEB if we didnot get the lock on the PEB it fails to scrub. Add that PEB again to the scrub list
Signed-off-by Bhavesh Parekh <[email protected]>Pushed to ubi-2.6.git with minor amendments, but please, do confirm that you verify that this patch fixes the issue you described.
Thanks!
--
Best Regards,
Artem Bityutskiy* Unknown Key
*0x7DC2A2B4
Quoted 4 lines · Bhavesh Parekh
Artem,
Currently we have K36 setup with most of the critical ubi fixes in it. Verified that this patch fixes the mentioned issue. Also we have K39 tree and I am planning to verify the this issue in that tree as well after porting the change and fixes from the ubi tree.
Thanks. I've added CC to stable in the commit message.
Artem.