ext4: fixed alignment and minor code cleanup in ext4.h
Signed-off-by: Petros Koutoupis <petros@petroskoutoupis.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu>
This commit is contained in:
parent
2244642310
commit
e7093f0d63
@ -2000,7 +2000,6 @@ static inline u32 ext4_chksum(struct ext4_sb_info *sbi, u32 crc,
|
||||
struct shash_desc shash;
|
||||
char ctx[4];
|
||||
} desc;
|
||||
int err;
|
||||
|
||||
BUG_ON(crypto_shash_descsize(sbi->s_chksum_driver)!=sizeof(desc.ctx));
|
||||
|
||||
@ -2008,8 +2007,7 @@ static inline u32 ext4_chksum(struct ext4_sb_info *sbi, u32 crc,
|
||||
desc.shash.flags = 0;
|
||||
*(u32 *)desc.ctx = crc;
|
||||
|
||||
err = crypto_shash_update(&desc.shash, address, length);
|
||||
BUG_ON(err);
|
||||
BUG_ON(crypto_shash_update(&desc.shash, address, length));
|
||||
|
||||
return *(u32 *)desc.ctx;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user