aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/dm-raid.c
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2016-01-11 17:47:25 -0800
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2016-01-11 17:47:25 -0800
commit009f773836513960d3982e80c86e266d25528563 (patch)
tree7315e5666698997dee34a80c1a1db801d3f8879b /drivers/md/dm-raid.c
parentInput: i8042 - add Fujitsu Lifebook U745 to the nomux list (diff)
parentInput: elantech - mark protocols v2 and v3 as semi-mt (diff)
downloadlinux-dev-009f773836513960d3982e80c86e266d25528563.tar.xz
linux-dev-009f773836513960d3982e80c86e266d25528563.zip
Merge branch 'next' into for-linus
Prepare first round of input updates for 4.5 merge window.
Diffstat (limited to 'drivers/md/dm-raid.c')
-rw-r--r--drivers/md/dm-raid.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/md/dm-raid.c b/drivers/md/dm-raid.c
index 97e165183e79..a0901214aef5 100644
--- a/drivers/md/dm-raid.c
+++ b/drivers/md/dm-raid.c
@@ -329,8 +329,7 @@ static int validate_region_size(struct raid_set *rs, unsigned long region_size)
*/
if (min_region_size > (1 << 13)) {
/* If not a power of 2, make it the next power of 2 */
- if (min_region_size & (min_region_size - 1))
- region_size = 1 << fls(region_size);
+ region_size = roundup_pow_of_two(min_region_size);
DMINFO("Choosing default region size of %lu sectors",
region_size);
} else {