dm cache: fix some issues with the new discard range support
authorJoe Thornber <ejt@redhat.com>
Mon, 24 Nov 2014 14:05:16 +0000 (14:05 +0000)
committerMike Snitzer <snitzer@redhat.com>
Mon, 1 Dec 2014 16:30:09 +0000 (11:30 -0500)
commit2572629a1318eb9e13e70fa59756d7bcfb80319e
tree7162438bb121f9e4c101425d36c246ce3cb5e935
parent8001e87d0ee98787c46f14f5f4f97aced70f119f
dm cache: fix some issues with the new discard range support

Commit 7ae34e777 ("dm cache: improve discard support") needed to also:
- discontinue having DM core split the discard bios on cache block
  boundaries
- calculate the cache's discard_nr_blocks relative to the determined
  discard_block_size rather than using oblock_to_dblock()

Signed-off-by: Joe Thornber <ejt@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
drivers/md/dm-cache-target.c