lkml.org 
[lkml]   [2014]   [Jun]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 3.13 179/212] dm cache: always split discards on cache block boundaries
    Date
    3.13.11.4 -stable review patch.  If anyone has any objections, please let me know.

    ------------------

    From: Heinz Mauelshagen <heinzm@redhat.com>

    commit f1daa838e861ae1a0fb7cd9721a21258430fcc8c upstream.

    The DM cache target cannot cope with discards that span multiple cache
    blocks, so each discard bio that spans more than one cache block must
    get split by the DM core.

    Signed-off-by: Heinz Mauelshagen <heinzm@redhat.com>
    Acked-by: Joe Thornber <ejt@redhat.com>
    Signed-off-by: Mike Snitzer <snitzer@redhat.com>
    Signed-off-by: Kamal Mostafa <kamal@canonical.com>
    ---
    drivers/md/dm-cache-target.c | 2 ++
    1 file changed, 2 insertions(+)

    diff --git a/drivers/md/dm-cache-target.c b/drivers/md/dm-cache-target.c
    index 1d30f65..fd92101 100644
    --- a/drivers/md/dm-cache-target.c
    +++ b/drivers/md/dm-cache-target.c
    @@ -2184,6 +2184,8 @@ static int cache_create(struct cache_args *ca, struct cache **result)
    ti->num_discard_bios = 1;
    ti->discards_supported = true;
    ti->discard_zeroes_data_unsupported = true;
    + /* Discard bios must be split on a block boundary */
    + ti->split_discard_bios = true;

    cache->features = ca->features;
    ti->per_bio_data_size = get_per_bio_data_size(cache);
    --
    1.9.1


    \
     
     \ /
      Last update: 2014-06-18 01:01    [W:4.042 / U:0.024 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site