A typo in osd_declare_write_commit() makes ASAN emit warnings like:
UBSAN: Undefined behaviour in /lustre/osd-ldiskfs/osd_io.c:1404:2
shift exponent 4096 is too large for 32-bit type 'int'
Change-Id: Ie612d9c6655211445c00bd17fa1bf7a836af3542
Fixes:
f0f92773e ("LU-14187 osd-ldiskfs: fix locking in write commit")
Signed-off-by: Andrew Perepechko <andrew.perepechko@hpe.com>
Reviewed-on: https://review.whamcloud.com/45423
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Li Dongyang <dongyangli@ddn.com>
* heavily-fragmented, it will be reduced to 4K at the worst.
*/
extent_bytes = osd_extent_bytes(osd);
- LASSERT(extent_bytes >= (1 << osd_sb(osd)->s_blocksize));
+ LASSERT(extent_bytes >= osd_sb(osd)->s_blocksize);
/* calculate number of extents (probably better to pass nb) */
for (i = 0; i < npages; i++) {