Linux kernel crash report:
loop0: detected capacity change from 0 to 8192
REISERFS warning:  read_super_block: reiserfs filesystem is deprecated and scheduled to be removed from the kernel in 2025
REISERFS (device loop0): found reiserfs format "3.5" with non-standard journal
REISERFS (device loop0): using ordered data mode
reiserfs: using flush barriers
==================================================================
BUG: KASAN: user-memory-access in instrument_atomic_read_write include/linux/instrumented.h:96 [inline]
BUG: KASAN: user-memory-access in test_and_set_bit_lock include/asm-generic/bitops/instrumented-lock.h:57 [inline]
BUG: KASAN: user-memory-access in bit_spin_lock include/linux/bit_spinlock.h:27 [inline]
BUG: KASAN: user-memory-access in zram_slot_lock+0x57/0x150 drivers/block/zram/zram_drv.c:67
Write of size 8 at addr 0000000000004128 by task syz-executor326/4993

CPU: 1 PID: 4993 Comm: syz-executor326 Not tainted 6.4.0-rc3-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/28/2023
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1e7/0x2d0 lib/dump_stack.c:106
 print_report+0xe6/0x540 mm/kasan/report.c:465
 kasan_report+0x176/0x1b0 mm/kasan/report.c:572
 kasan_check_range+0x283/0x290 mm/kasan/generic.c:187
 instrument_atomic_read_write include/linux/instrumented.h:96 [inline]
 test_and_set_bit_lock include/asm-generic/bitops/instrumented-lock.h:57 [inline]
 bit_spin_lock include/linux/bit_spinlock.h:27 [inline]
 zram_slot_lock+0x57/0x150 drivers/block/zram/zram_drv.c:67
 zram_read_page drivers/block/zram/zram_drv.c:1362 [inline]
 zram_bvec_read drivers/block/zram/zram_drv.c:1409 [inline]
 zram_bio_read drivers/block/zram/zram_drv.c:1883 [inline]
 zram_submit_bio+0x18bc/0x26d0 drivers/block/zram/zram_drv.c:1933
 __submit_bio+0x205/0x2e0 block/blk-core.c:598
 __submit_bio_noacct block/blk-core.c:641 [inline]
 submit_bio_noacct_nocheck+0x467/0xc60 block/blk-core.c:704
 submit_bh fs/buffer.c:2782 [inline]
 __bread_slow fs/buffer.c:1226 [inline]
 __bread_gfp+0x1ec/0x380 fs/buffer.c:1419
 __bread include/linux/buffer_head.h:471 [inline]
 journal_init+0xf61/0x24b0 fs/reiserfs/journal.c:2788
 reiserfs_fill_super+0x1039/0x2620 fs/reiserfs/super.c:2022
 mount_bdev+0x274/0x3a0 fs/super.c:1380
 legacy_get_tree+0xef/0x190 fs/fs_context.c:610
 vfs_get_tree+0x8c/0x270 fs/super.c:1510
 do_new_mount+0x28f/0xae0 fs/namespace.c:3039
 do_mount fs/namespace.c:3382 [inline]
 __do_sys_mount fs/namespace.c:3591 [inline]
 __se_sys_mount+0x2d9/0x3c0 fs/namespace.c:3568
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f185eef5b0a
Code: 83 c4 08 5b 5d c3 66 2e 0f 1f 84 00 00 00 00 00 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 c0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffe122853a8 EFLAGS: 00000286 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 00007f185eef5b0a
RDX: 0000000020000080 RSI: 0000000020000140 RDI: 00007ffe122853b0
RBP: 00007ffe122853b0 R08: 00007ffe122853f0 R09: 0000000000001121
R10: 000000000120c083 R11: 0000000000000286 R12: 0000000000000004
R13: 00005555570882c0 R14: 00007ffe122853f0 R15: 0000000000000000
 </TASK>
==================================================================


Fix patch:
diff --git a/block/blk-core.c b/block/blk-core.c
index 00c74330fa92..1da77e7d6289 100644
--- a/block/blk-core.c
+++ b/block/blk-core.c
@@ -520,7 +520,7 @@ static inline int bio_check_eod(struct bio *bio)
 	sector_t maxsector = bdev_nr_sectors(bio->bi_bdev);
 	unsigned int nr_sectors = bio_sectors(bio);
 
-	if (nr_sectors && maxsector &&
+	if (nr_sectors &&
 	    (nr_sectors > maxsector ||
 	     bio->bi_iter.bi_sector > maxsector - nr_sectors)) {
 		pr_info_ratelimited("%s: attempt to access beyond end of device\n"