mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 19:21:31 -04:00
fs: add i_blocksize()
Replace all 1 << inode->i_blkbits and (1 << inode->i_blkbits) in fs branch. This patch also fixes multiple checkpatch warnings: WARNING: Prefer 'unsigned int' to bare use of 'unsigned' Thanks to Andrew Morton for suggesting more appropriate function instead of macro. [[email protected]: truncate: use i_blocksize()] Link: http://lkml.kernel.org/r/9c8b2cd83c8f5653805d43debde9fa8817e02fc4.1484895804.git.geliangtang@gmail.com Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Fabian Frederick <[email protected]> Signed-off-by: Geliang Tang <[email protected]> Cc: Alexander Viro <[email protected]> Cc: Ross Zwisler <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
d317120097
commit
93407472a2
27 changed files with 56 additions and 51 deletions
|
|
@ -189,7 +189,7 @@ int reiserfs_commit_page(struct inode *inode, struct page *page,
|
|||
int ret = 0;
|
||||
|
||||
th.t_trans_id = 0;
|
||||
blocksize = 1 << inode->i_blkbits;
|
||||
blocksize = i_blocksize(inode);
|
||||
|
||||
if (logit) {
|
||||
reiserfs_write_lock(s);
|
||||
|
|
|
|||
|
|
@ -525,7 +525,7 @@ static int reiserfs_get_blocks_direct_io(struct inode *inode,
|
|||
* referenced in convert_tail_for_hole() that may be called from
|
||||
* reiserfs_get_block()
|
||||
*/
|
||||
bh_result->b_size = (1 << inode->i_blkbits);
|
||||
bh_result->b_size = i_blocksize(inode);
|
||||
|
||||
ret = reiserfs_get_block(inode, iblock, bh_result,
|
||||
create | GET_BLOCK_NO_DANGLE);
|
||||
|
|
|
|||
Loading…
Reference in a new issue