22 Oct, 2016

1 commit


12 Oct, 2016

1 commit

  • Current bad block clear implementation assumes the range to clear
    overlaps with at least one bad block already stored. If given range to
    clear precedes first bad block in a list, the first entry is incorrectly
    updated.

    Check not only if stored block end is past clear block end but also if
    stored block start is before clear block end.

    Signed-off-by: Tomasz Majchrzak
    Acked-by: NeilBrown
    Signed-off-by: Jens Axboe

    Tomasz Majchrzak
     

10 Jan, 2016

3 commits

  • Provide a devres interface for initializing a badblocks instance. The
    pmem driver has several scenarios where it will be beneficial to have
    this structure automatically freed when the device is disabled / fails
    probe.

    Signed-off-by: Dan Williams

    Dan Williams
     
  • The badblocks list attached to a gendisk is allocated by the driver
    which equates to the driver owning the lifetime of the object. Do not
    automatically free it in del_gendisk(). This is in preparation for
    expanding the use of badblocks in libnvdimm drivers and introducing
    devm_init_badblocks().

    Signed-off-by: Dan Williams

    Dan Williams
     
  • For symmetry with badblocks_init() make it clear that this path only
    destroys incremental allocations of a badblocks instance, and does not
    free the badblocks instance itself.

    Signed-off-by: Dan Williams

    Dan Williams
     

09 Jan, 2016

1 commit

  • Take the core badblocks implementation from md, and make it generally
    available. This follows the same style as kernel implementations of
    linked lists, rb-trees etc, where you can have a structure that can be
    embedded anywhere, and accessor functions to manipulate the data.

    The only changes in this copy of the code are ones to generalize
    function/variable names from md-specific ones. Also add init and free
    functions.

    Signed-off-by: Vishal Verma
    Signed-off-by: Dan Williams

    Vishal Verma