lkml.org 
[lkml]   [2014]   [Oct]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    SubjectRe: [PATCH 3/4] UBI: Fastmap: Care about the protection queue
    From
    Date
    On Mon, 2014-10-20 at 17:59 +0200, Richard Weinberger wrote:
    > > Also, say, PEB X is in the work queue waiting for erasure. Fastmap comes
    > > along and saves it as "must be erased" in the fastmap. Fastmap finishes
    > > its job, PEB X gets erased, and I write my data there, so PEB X is
    > > referred to by LEB Y. Now I have power cut. Then I attach the flash
    > > again. Surely it is not that fastmap just erases PEB X and I lose the
    > > contents of LEB Y?
    >
    > This cannot happen. If X is erased you cannot write data do it. I must first go
    > thought the pool and the pool is scanned while attaching.

    Just noticed from the code that we first add PEBs to the erase list, and
    then we go an scan the pools.



    \
     
     \ /
      Last update: 2014-10-20 18:41    [W:4.056 / U:0.368 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site