aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/persistent-data/dm-btree-remove.c
diff options
context:
space:
mode:
authorTomohiro Kusumi <kusumi.tomohiro@gmail.com>2015-10-29 03:54:21 +0900
committerMike Snitzer <snitzer@redhat.com>2015-10-31 19:06:06 -0400
commitaad9ae4550755edc020b5c511a8b54f0104b2f47 (patch)
treea94ce06ad5d8fe99c92a09c80ed60c7d8c8882a6 /drivers/md/persistent-data/dm-btree-remove.c
parentdm delay: document that offsets are specified in sectors (diff)
downloadlinux-dev-aad9ae4550755edc020b5c511a8b54f0104b2f47.tar.xz
linux-dev-aad9ae4550755edc020b5c511a8b54f0104b2f47.zip
dm switch: simplify conditional in alloc_region_table()
The variable sctx->nr_regions has type unsigned long and the variable nr_regions has type sector_t. Thus the variables may be different when overflow happens. Changed the conditional to "if (nr_regions >= ULONG_MAX)". Also move the assignment of nr_regions after sector_div() and the sanity check which looks more sane. Signed-off-by: Tomohiro Kusumi <kusumi.tomohiro@gmail.com> Reviewed-by: Mikulas Patocka <mpatocka@redhat.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'drivers/md/persistent-data/dm-btree-remove.c')
0 files changed, 0 insertions, 0 deletions