diff options
Diffstat (limited to 'fs/xfs/xfs_log_recover.c')
| -rw-r--r-- | fs/xfs/xfs_log_recover.c | 4 | 
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/xfs/xfs_log_recover.c b/fs/xfs/xfs_log_recover.c index 82c81d20459d..13b94d2e605b 100644 --- a/fs/xfs/xfs_log_recover.c +++ b/fs/xfs/xfs_log_recover.c @@ -329,7 +329,7 @@ xlog_find_verify_cycle(  	 * try a smaller size.  We need to be able to read at least  	 * a log sector, or we're out of luck.  	 */ -	bufblks = 1 << ffs(nbblks); +	bufblks = roundup_pow_of_two(nbblks);  	while (bufblks > log->l_logBBsize)  		bufblks >>= 1;  	while (!(buffer = xlog_alloc_buffer(log, bufblks))) { @@ -1528,7 +1528,7 @@ xlog_write_log_records(  	 * a smaller size.  We need to be able to write at least a  	 * log sector, or we're out of luck.  	 */ -	bufblks = 1 << ffs(blocks); +	bufblks = roundup_pow_of_two(blocks);  	while (bufblks > log->l_logBBsize)  		bufblks >>= 1;  	while (!(buffer = xlog_alloc_buffer(log, bufblks))) {  | 
