All of lore.kernel.org
 help / color / mirror / Atom feed
From: syzbot <syzbot+da80e6a47db00f8be22c@syzkaller.appspotmail.com>
To: axboe@kernel.dk, linux-block@vger.kernel.org,
	linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com
Subject: [syzbot] [block?] KCSAN: data-race in __mod_timer / blk_add_timer (6)
Date: Mon, 24 Apr 2023 00:21:45 -0700	[thread overview]
Message-ID: <000000000000ff17f705fa0fdbd7@google.com> (raw)

Hello,

syzbot found the following issue on:

HEAD commit:    148341f0a2f5 Merge tag 'vfs.misc.fixes.v6.3-rc6' of git://..
git tree:       upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=11a5970dc80000
kernel config:  https://syzkaller.appspot.com/x/.config?x=54d63ee086ae78d0
dashboard link: https://syzkaller.appspot.com/bug?extid=da80e6a47db00f8be22c
compiler:       Debian clang version 15.0.7, GNU ld (GNU Binutils for Debian) 2.35.2

Unfortunately, I don't have any reproducer for this issue yet.

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/1c557f92a6e1/disk-148341f0.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/f2c85210e1ce/vmlinux-148341f0.xz
kernel image: https://storage.googleapis.com/syzbot-assets/b019d0447709/bzImage-148341f0.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+da80e6a47db00f8be22c@syzkaller.appspotmail.com

==================================================================
BUG: KCSAN: data-race in __mod_timer / blk_add_timer

write to 0xffff88810285dd20 of 8 bytes by task 26833 on cpu 0:
 __mod_timer+0x625/0x890 kernel/time/timer.c:1121
 mod_timer+0x1f/0x30 kernel/time/timer.c:1190
 blk_add_timer+0x184/0x190 block/blk-timeout.c:164
 blk_mq_start_request+0x100/0x2b0 block/blk-mq.c:1264
 scsi_queue_rq+0x143b/0x1990 drivers/scsi/scsi_lib.c:1756
 blk_mq_dispatch_rq_list+0x7b1/0x11f0 block/blk-mq.c:2059
 __blk_mq_do_dispatch_sched block/blk-mq-sched.c:172 [inline]
 blk_mq_do_dispatch_sched+0x4de/0x820 block/blk-mq-sched.c:186
 __blk_mq_sched_dispatch_requests+0x1c1/0x260
 blk_mq_sched_dispatch_requests+0x93/0x100 block/blk-mq-sched.c:338
 __blk_mq_run_hw_queue+0x8e/0x110 block/blk-mq.c:2177
 __blk_mq_delay_run_hw_queue+0xb3/0x3a0 block/blk-mq.c:2253
 blk_mq_run_hw_queue+0x19f/0x330 block/blk-mq.c:2301
 blk_mq_sched_insert_requests+0x1da/0x2c0 block/blk-mq-sched.c:492
 blk_mq_dispatch_plug_list block/blk-mq.c:2748 [inline]
 blk_mq_flush_plug_list+0x519/0x660 block/blk-mq.c:2790
 __blk_flush_plug+0x223/0x280 block/blk-core.c:1153
 blk_finish_plug+0x47/0x60 block/blk-core.c:1177
 ext4_do_writepages+0x1c08/0x2140 fs/ext4/inode.c:2927
 ext4_writepages+0x127/0x250 fs/ext4/inode.c:2964
 do_writepages+0x1c5/0x340 mm/page-writeback.c:2551
 filemap_fdatawrite_wbc+0xdb/0xf0 mm/filemap.c:390
 __filemap_fdatawrite_range mm/filemap.c:423 [inline]
 file_write_and_wait_range+0xfa/0x190 mm/filemap.c:781
 ext4_sync_file+0x10d/0x720 fs/ext4/fsync.c:151
 vfs_fsync_range+0x10b/0x120 fs/sync.c:188
 generic_write_sync include/linux/fs.h:2452 [inline]
 ext4_buffered_write_iter+0x397/0x3e0 fs/ext4/file.c:296
 ext4_file_write_iter+0xd7/0x10e0
 do_iter_write+0x418/0x700 fs/read_write.c:861
 vfs_iter_write+0x50/0x70 fs/read_write.c:902
 iter_file_splice_write+0x456/0x7d0 fs/splice.c:778
 do_splice_from fs/splice.c:856 [inline]
 direct_splice_actor+0x84/0xa0 fs/splice.c:1022
 splice_direct_to_actor+0x2ee/0x5f0 fs/splice.c:977
 do_splice_direct+0x104/0x180 fs/splice.c:1065
 do_sendfile+0x3b8/0x950 fs/read_write.c:1255
 __do_sys_sendfile64 fs/read_write.c:1317 [inline]
 __se_sys_sendfile64 fs/read_write.c:1309 [inline]
 __x64_sys_sendfile64+0xbd/0x150 fs/read_write.c:1309
 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

read to 0xffff88810285dd20 of 8 bytes by task 2708 on cpu 1:
 blk_add_timer+0x118/0x190
 blk_mq_start_request+0x100/0x2b0 block/blk-mq.c:1264
 scsi_queue_rq+0x143b/0x1990 drivers/scsi/scsi_lib.c:1756
 blk_mq_dispatch_rq_list+0x7b1/0x11f0 block/blk-mq.c:2059
 __blk_mq_do_dispatch_sched block/blk-mq-sched.c:172 [inline]
 blk_mq_do_dispatch_sched+0x4de/0x820 block/blk-mq-sched.c:186
 __blk_mq_sched_dispatch_requests+0x1c1/0x260
 blk_mq_sched_dispatch_requests+0x93/0x100 block/blk-mq-sched.c:338
 __blk_mq_run_hw_queue+0x8e/0x110 block/blk-mq.c:2177
 __blk_mq_delay_run_hw_queue+0xb3/0x3a0 block/blk-mq.c:2253
 blk_mq_run_hw_queue+0x19f/0x330 block/blk-mq.c:2301
 blk_mq_sched_insert_requests+0x1da/0x2c0 block/blk-mq-sched.c:492
 blk_mq_dispatch_plug_list block/blk-mq.c:2748 [inline]
 blk_mq_flush_plug_list+0x519/0x660 block/blk-mq.c:2790
 __blk_flush_plug+0x223/0x280 block/blk-core.c:1153
 blk_finish_plug+0x47/0x60 block/blk-core.c:1177
 jbd2_journal_commit_transaction+0x1c09/0x33f0 fs/jbd2/commit.c:797
 kjournald2+0x242/0x420 fs/jbd2/journal.c:209
 kthread+0x1ac/0x1e0 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:308

value changed: 0x0000000100014674 -> 0x00000001000148f4

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 2708 Comm: jbd2/sda1-8 Not tainted 6.3.0-rc5-syzkaller-00005-g148341f0a2f5 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/02/2023
==================================================================


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzkaller@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

             reply	other threads:[~2023-04-24  7:22 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-24  7:21 syzbot [this message]
2023-04-24  7:45 ` [syzbot] [block?] KCSAN: data-race in __mod_timer / blk_add_timer (6) Dmitry Vyukov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=000000000000ff17f705fa0fdbd7@google.com \
    --to=syzbot+da80e6a47db00f8be22c@syzkaller.appspotmail.com \
    --cc=axboe@kernel.dk \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=syzkaller-bugs@googlegroups.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.