BUG: corrupted list in nvmet_fc_remove_port
Subsystems (3)
syzbot
syzbotHello,
syzbot found the following issue on:
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (++20260613092233+e80beda6e255-1~exp1~20260613092250.77), Debian LLD 22.1.8 syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/d24cfbd75fba/disk-a5ebb762.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/d0874c703893/vmlinux-a5ebb762.xz
kernel image: https://storage.googleapis.com/syzbot-assets/2a424fa32a7b/bzImage-a5ebb762.xz
IMPORTANT: if you fix the issue, please add the following tag to the commit:
nvmet_tcp: enabling port 1 (127.0.0.1:4420)
non-slab/vmalloc memorylist_del corruption. prev->next should be ffff88802af3b020, but was 0000000000000000. (prev=ffffffff9aecd340)
------------[ cut here ]------------
kernel BUG at lib/list_debug.c:64!
Oops: invalid opcode: 0000 [#1] SMP KASAN PTI
CPU: 0 UID: 0 PID: 5680 Comm: syz-executor403 Not tainted syzkaller #0 PREEMPT_{RT,(full)}
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/24/2026
RIP: 0010:__list_del_entry_valid_or_report+0x15a/0x190 lib/list_debug.c:62
Code: e8 ab ea 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 6c b1 58 fd 49 8b 17 48 c7 c7 40 71 cc 8b 48 89 de 4c 89 f9 e8 a7 7a 4c fc 90 <0f> 0b 4c 89 f7 e8 7c ea 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 3d
RSP: 0018:ffffc90004cdfc30 EFLAGS: 00010246
RAX: 000000000000006d RBX: ffff88802af3b020 RCX: 7d3c36a647dfae00
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000201 R08: 0000000000000000 R09: 0000000000000000
R10: dffffc0000000000 R11: ffffed101708490b R12: 1ffffffff35d9a68
R13: dffffc0000000000 R14: ffffffff85f7f740 R15: ffffffff9aecd340
FS: 0000555594721400(0000) GS:ffff8881249bb000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000555594721340 CR3: 0000000038dd8000 CR4: 00000000003526f0
Call Trace:
<TASK>
__list_del_entry_valid include/linux/list.h:140 [inline]
__list_del_entry include/linux/list.h:261 [inline]
list_del include/linux/list.h:275 [inline]
nvmet_fc_portentry_unbind drivers/nvme/target/fc.c:1281 [inline]
nvmet_fc_remove_port+0x16b/0x320 drivers/nvme/target/fc.c:2927
nvmet_disable_port+0x13e/0x1f0 drivers/nvme/target/core.c:400
nvmet_port_subsys_drop_link+0x1e8/0x210 drivers/nvme/target/configfs.c:1123
configfs_unlink+0x44f/0x6b0 fs/configfs/symlink.c:258
vfs_unlink+0x27b/0x6e0 fs/namei.c:5678
filename_unlinkat+0x3d3/0x610 fs/namei.c:5748
__do_sys_unlinkat fs/namei.c:5777 [inline]
__se_sys_unlinkat+0x83/0x1a0 fs/namei.c:5769
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f0ad400d8b9
Code: c0 79 93 eb d5 48 8d 7c 1d 00 eb 99 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 d8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffe650d4178 EFLAGS: 00000246 ORIG_RAX: 0000000000000107
RAX: ffffffffffffffda RBX: 0000200000000780 RCX: 00007f0ad400d8b9
RDX: 0000000000000000 RSI: 0000200000000780 RDI: 00000000ffffff9c
RBP: 00000000000f4240 R08: 0000000000000009 R09: 0000000000000009
R10: 0000000000000009 R11: 0000000000000246 R12: 0000000000014e22
R13: 00007ffe650d418c R14: 00007ffe650d41a0 R15: 00007ffe650d4190
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:__list_del_entry_valid_or_report+0x15a/0x190 lib/list_debug.c:62
Code: e8 ab ea 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 6c b1 58 fd 49 8b 17 48 c7 c7 40 71 cc 8b 48 89 de 4c 89 f9 e8 a7 7a 4c fc 90 <0f> 0b 4c 89 f7 e8 7c ea 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 3d
RSP: 0018:ffffc90004cdfc30 EFLAGS: 00010246
RAX: 000000000000006d RBX: ffff88802af3b020 RCX: 7d3c36a647dfae00
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000201 R08: 0000000000000000 R09: 0000000000000000
R10: dffffc0000000000 R11: ffffed101708490b R12: 1ffffffff35d9a68
R13: dffffc0000000000 R14: ffffffff85f7f740 R15: ffffffff9aecd340
FS: 0000555594721400(0000) GS:ffff8881249bb000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000555594721340 CR3: 0000000038dd8000 CR4: 00000000003526f0---
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 [email protected].
syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.
If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title
If you want syzbot to run the reproducer, reply with:
#syz test: git://repo/address.git branch-or-commit-hash
If you attach or paste a git patch, syzbot will apply it before testing.
If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)
If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report
If you want to undo deduplication, reply with:
#syz undup
Quoted 5 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview]
Hello,syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
#syz test
drivers/nvme/target/fc.c +1 -1
@@ -1278,7 +1278,6 @@ nvmet_fc_portentry_unbind(struct nvmet_fnvmet_fc_tgtport_put (pe->tgtport); pe->tgtport->pe =NULL ; } -list_del (&pe->pe_list);spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags); }
@@ -2922,6 +2921,7 @@ nvmet_fc_remove_port(struct nvmet_port *spin_lock_irqsave (&nvmet_fc_tgtlock, flags);if (pe->tgtport &&nvmet_fc_tgtport_get (pe->tgtport)) tgtport = pe->tgtport; +list_del (&pe->pe_list);spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags);nvmet_fc_portentry_unbind (pe);
--
syzbot
syzbotsyzbot has tested the proposed patch but the reproducer is still triggering an issue:
Hello,
syzbot has tested the proposed patch but the reproducer is still triggering an issue:
BUG: corrupted list in nvmet_fc_remove_port
non-slab/vmalloc memorylist_del corruption. prev->next should be ffff8880387ec820, but was 0000000000000000. (prev=ffffffff9aecd340)
------------[ cut here ]------------
kernel BUG at lib/list_debug.c:64!
Oops: invalid opcode: 0000 [#1] SMP KASAN PTI
CPU: 0 UID: 0 PID: 6847 Comm: syz.0.45 Not tainted syzkaller #0 PREEMPT_{RT,(full)}
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026
RIP: 0010:__list_del_entry_valid_or_report+0x15a/0x190 lib/list_debug.c:62
Code: e8 8b f8 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 4c bf 58 fd 49 8b 17 48 c7 c7 40 6e cc 8b 48 89 de 4c 89 f9 e8 27 88 4c fc 90 <0f> 0b 4c 89 f7 e8 5c f8 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 1d
RSP: 0018:ffffc90004f8fc30 EFLAGS: 00010246
RAX: 000000000000006d RBX: ffff8880387ec820 RCX: 4b2bacb912474a00
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000001 R08: 0000000000000000 R09: 0000000000000000
R10: dffffc0000000000 R11: ffffed101708490b R12: 1ffffffff35d9a68
R13: dffffc0000000000 R14: ffffffff85f7e800 R15: ffffffff9aecd340
FS: 00007f415b0fd6c0(0000) GS:ffff8881249bb000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fa587c4b8c0 CR3: 0000000037614000 CR4: 00000000003526f0
Call Trace:
<TASK>
__list_del_entry_valid include/linux/list.h:140 [inline]
__list_del_entry include/linux/list.h:261 [inline]
list_del include/linux/list.h:275 [inline]
nvmet_fc_remove_port+0xbc/0x340 drivers/nvme/target/fc.c:2924
nvmet_disable_port+0x13e/0x1f0 drivers/nvme/target/core.c:400
nvmet_port_subsys_drop_link+0x1e8/0x210 drivers/nvme/target/configfs.c:1123
configfs_unlink+0x44f/0x6b0 fs/configfs/symlink.c:258
vfs_unlink+0x27b/0x6e0 fs/namei.c:5678
filename_unlinkat+0x3d3/0x610 fs/namei.c:5748
__do_sys_unlinkat fs/namei.c:5777 [inline]
__se_sys_unlinkat+0x83/0x1a0 fs/namei.c:5769
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f415babe1d9
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f415b0fd028 EFLAGS: 00000246 ORIG_RAX: 0000000000000107
RAX: ffffffffffffffda RBX: 00007f415bd46090 RCX: 00007f415babe1d9
RDX: 0000000000000000 RSI: 0000200000000780 RDI: ffffffffffffff9c
RBP: 00007f415bb55888 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f415bd46128 R14: 00007f415bd46090 R15: 00007ffda341e7e8
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:__list_del_entry_valid_or_report+0x15a/0x190 lib/list_debug.c:62
Code: e8 8b f8 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 4c bf 58 fd 49 8b 17 48 c7 c7 40 6e cc 8b 48 89 de 4c 89 f9 e8 27 88 4c fc 90 <0f> 0b 4c 89 f7 e8 5c f8 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 1d
RSP: 0018:ffffc90004f8fc30 EFLAGS: 00010246
RAX: 000000000000006d RBX: ffff8880387ec820 RCX: 4b2bacb912474a00
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000001 R08: 0000000000000000 R09: 0000000000000000
R10: dffffc0000000000 R11: ffffed101708490b R12: 1ffffffff35d9a68
R13: dffffc0000000000 R14: ffffffff85f7e800 R15: ffffffff9aecd340
FS: 00007f415b0fd6c0(0000) GS:ffff8881249bb000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fa587c4b8c0 CR3: 0000000037614000 CR4: 00000000003526f0Tested on:
commit: 24a19b95 Linux 7.3-rc7 git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=160b540d580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (++20260613092233+e80beda6e255-1~exp1~20260613092250.77), Debian LLD 22.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=1493540d580000
Quoted 5 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview]
Hello,syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
#syz test
drivers/nvme/target/fc.c +7 -0
@@ -1273,7 +1273,14 @@ nvmet_fc_portentry_unbind(struct nvmet_f {unsigned long flags; +if (!pe->port) +return ;spin_lock_irqsave (&nvmet_fc_tgtlock, flags); +if (!pe->port) { +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags); +return ; + } + pe->port =NULL ;if (pe->tgtport) {nvmet_fc_tgtport_put (pe->tgtport); pe->tgtport->pe =NULL ;
--
syzbot
syzbotsyzbot has tested the proposed patch but the reproducer is still triggering an issue:
Hello,
syzbot has tested the proposed patch but the reproducer is still triggering an issue:
BUG: corrupted list in nvmet_fc_remove_port
non-slab/vmalloc memorylist_del corruption. prev->next should be ffff88805f6be020, but was 0000000000000000. (prev=ffffffff9aecd340)
------------[ cut here ]------------
kernel BUG at lib/list_debug.c:64!
Oops: invalid opcode: 0000 [#1] SMP KASAN PTI
CPU: 0 UID: 0 PID: 6706 Comm: syz.1.55 Not tainted syzkaller #0 PREEMPT_{RT,(full)}
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026
RIP: 0010:__list_del_entry_valid_or_report+0x15a/0x190 lib/list_debug.c:62
Code: e8 8b f8 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 4c bf 58 fd 49 8b 17 48 c7 c7 40 6e cc 8b 48 89 de 4c 89 f9 e8 27 88 4c fc 90 <0f> 0b 4c 89 f7 e8 5c f8 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 1d
RSP: 0018:ffffc90005077c38 EFLAGS: 00010246
RAX: 000000000000006d RBX: ffff88805f6be020 RCX: 3022935dcdf04700
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000201 R08: 0000000000000000 R09: 0000000000000000
R10: dffffc0000000000 R11: ffffed101708490b R12: 1ffffffff35d9a68
R13: dffffc0000000000 R14: ffffffff85f7e840 R15: ffffffff9aecd340
FS: 00007f556375d6c0(0000) GS:ffff8881249bb000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fcf66ae41d8 CR3: 0000000035112000 CR4: 00000000003526f0
Call Trace:
<TASK>
__list_del_entry_valid include/linux/list.h:140 [inline]
__list_del_entry include/linux/list.h:261 [inline]
list_del include/linux/list.h:275 [inline]
nvmet_fc_portentry_unbind drivers/nvme/target/fc.c:1288 [inline]
nvmet_fc_remove_port+0x1fb/0x380 drivers/nvme/target/fc.c:2934
nvmet_disable_port+0x13e/0x1f0 drivers/nvme/target/core.c:400
nvmet_port_subsys_drop_link+0x1e8/0x210 drivers/nvme/target/configfs.c:1123
configfs_unlink+0x44f/0x6b0 fs/configfs/symlink.c:258
vfs_unlink+0x27b/0x6e0 fs/namei.c:5678
filename_unlinkat+0x3d3/0x610 fs/namei.c:5748
__do_sys_unlinkat fs/namei.c:5777 [inline]
__se_sys_unlinkat+0x83/0x1a0 fs/namei.c:5769
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f556411e1d9
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f556375d028 EFLAGS: 00000246 ORIG_RAX: 0000000000000107
RAX: ffffffffffffffda RBX: 00007f55643a6090 RCX: 00007f556411e1d9
RDX: 0000000000000000 RSI: 0000200000000780 RDI: ffffffffffffff9c
RBP: 00007f55641b5888 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f55643a6128 R14: 00007f55643a6090 R15: 00007ffde0760588
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:__list_del_entry_valid_or_report+0x15a/0x190 lib/list_debug.c:62
Code: e8 8b f8 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 4c bf 58 fd 49 8b 17 48 c7 c7 40 6e cc 8b 48 89 de 4c 89 f9 e8 27 88 4c fc 90 <0f> 0b 4c 89 f7 e8 5c f8 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 1d
RSP: 0018:ffffc90005077c38 EFLAGS: 00010246
RAX: 000000000000006d RBX: ffff88805f6be020 RCX: 3022935dcdf04700
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000201 R08: 0000000000000000 R09: 0000000000000000
R10: dffffc0000000000 R11: ffffed101708490b R12: 1ffffffff35d9a68
R13: dffffc0000000000 R14: ffffffff85f7e840 R15: ffffffff9aecd340
FS: 00007f556375d6c0(0000) GS:ffff8881249bb000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fcf66c6f040 CR3: 0000000035112000 CR4: 00000000003526f0Tested on:
commit: 24a19b95 Linux 7.3-rc7 git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=17e825d1580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (++20260613092233+e80beda6e255-1~exp1~20260613092250.77), Debian LLD 22.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=12c690a5580000
Quoted 5 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview]
Hello,syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
#syz test
drivers/nvme/target/fc.c +7 -4
@@ -2915,23 +2915,26 @@ nvmet_fc_add_port(struct nvmet_port *porstatic void nvmet_fc_remove_port (struct nvmet_port *port) { -struct nvmet_fc_port_entry *pe = port->priv; +struct nvmet_fc_port_entry *pe;struct nvmet_fc_tgtport *tgtport =NULL ;unsigned long flags;spin_lock_irqsave (&nvmet_fc_tgtlock, flags); -if (pe->tgtport &&nvmet_fc_tgtport_get (pe->tgtport)) + pe = port->priv; + port->priv =NULL ; +if (pe && pe->tgtport &&nvmet_fc_tgtport_get (pe->tgtport)) tgtport = pe->tgtport;spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags); -nvmet_fc_portentry_unbind (pe); -if (tgtport) {/* terminate any outstanding associations */ __nvmet_fc_free_assocs (tgtport);nvmet_fc_tgtport_put (tgtport); } +if (!pe) +return ; +nvmet_fc_portentry_unbind (pe);kfree (pe); }
--
syzbot
syzbotsyzbot has tested the proposed patch but the reproducer is still triggering an issue:
Hello,
syzbot has tested the proposed patch but the reproducer is still triggering an issue:
KASAN: user-memory-access Read in nvmet_fc_tgt_a_get
=========
==================================================================
BUG: KASAN: user-memory-access in instrument_atomic_read include/linux/instrumented.h:82 [inline]
BUG: KASAN: user-memory-access in atomic_read include/linux/atomic/atomic-instrumented.h:32 [inline]
BUG: KASAN: user-memory-access in refcount_read include/linux/refcount.h:170 [inline]
BUG: KASAN: user-memory-access in __refcount_add_not_zero include/linux/refcount.h:176 [inline]
BUG: KASAN: user-memory-access in __refcount_inc_not_zero include/linux/refcount.h:317 [inline]
BUG: KASAN: user-memory-access in refcount_inc_not_zero include/linux/refcount.h:335 [inline]
BUG: KASAN: user-memory-access in kref_get_unless_zero include/linux/kref.h:133 [inline]
BUG: KASAN: user-memory-access in nvmet_fc_tgt_a_get+0x82/0x1d0 drivers/nvme/target/fc.c:1201
Read of size 4 at addr 000000000008c617 by task syz.1.88/6756
CPU: 0 UID: 0 PID: 6756 Comm: syz.1.88 Not tainted syzkaller #0 PREEMPT_{RT,(full)}
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026
Call Trace:
<TASK>
dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120
kasan_report+0x117/0x150 mm/kasan/report.c:595
check_region_inline mm/kasan/generic.c:-1 [inline]
kasan_check_range+0x264/0x2c0 mm/kasan/generic.c:200
instrument_atomic_read include/linux/instrumented.h:82 [inline]
atomic_read include/linux/atomic/atomic-instrumented.h:32 [inline]
refcount_read include/linux/refcount.h:170 [inline]
__refcount_add_not_zero include/linux/refcount.h:176 [inline]
__refcount_inc_not_zero include/linux/refcount.h:317 [inline]
refcount_inc_not_zero include/linux/refcount.h:335 [inline]
kref_get_unless_zero include/linux/kref.h:133 [inline]
nvmet_fc_tgt_a_get+0x82/0x1d0 drivers/nvme/target/fc.c:1201
__nvmet_fc_free_assocs+0x10c/0x380 drivers/nvme/target/fc.c:1480
nvmet_fc_remove_port+0xc5/0x350 drivers/nvme/target/fc.c:2931
nvmet_disable_port+0x13e/0x1f0 drivers/nvme/target/core.c:400
nvmet_port_subsys_drop_link+0x1e8/0x210 drivers/nvme/target/configfs.c:1123
configfs_unlink+0x44f/0x6b0 fs/configfs/symlink.c:258
vfs_unlink+0x27b/0x6e0 fs/namei.c:5678
filename_unlinkat+0x3d3/0x610 fs/namei.c:5748
__do_sys_unlinkat fs/namei.c:5777 [inline]
__se_sys_unlinkat+0x83/0x1a0 fs/namei.c:5769
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fd82566e1d9
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fd824cad028 EFLAGS: 00000246 ORIG_RAX: 0000000000000107
RAX: ffffffffffffffda RBX: 00007fd8258f6090 RCX: 00007fd82566e1d9
RDX: 0000000000000000 RSI: 0000200000000780 RDI: ffffffffffffff9c
RBP: 00007fd825705888 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fd8258f6128 R14: 00007fd8258f6090 R15: 00007ffe18669a38
</TASK>
==================================================================Tested on:
commit: 24a19b95 Linux 7.3-rc7 git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=1710023e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (++20260613092233+e80beda6e255-1~exp1~20260613092250.77), Debian LLD 22.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=1432149c580000
Quoted 5 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview]
Hello,syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
#syz test
drivers/nvme/target/fc.c +5 -0
@@ -1620,6 +1620,7 @@ nvmet_fc_free_pending_reqs(struct nvmet_ } } +static DEFINE_MUTEX (tgtp_mutex);/** * nvmet_fc_unregister_targetport - transport entry point called by an * LLDD to deregister/remove a previously
@@ -1637,6 +1638,7 @@ nvmet_fc_unregister_targetport(struct nvstruct nvmet_fc_tgtport *tgtport =targetport_to_tgtport (target_port);unsigned long flags; +mutex_lock (&tgtp_mutex);spin_lock_irqsave (&nvmet_fc_tgtlock, flags);list_del (&tgtport->tgt_list);spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags);
@@ -1645,6 +1647,7 @@ nvmet_fc_unregister_targetport(struct nv/* terminate any outstanding associations */ __nvmet_fc_free_assocs (tgtport); +mutex_unlock (&tgtp_mutex);flush_workqueue (nvmet_wq);
@@ -2919,6 +2922,7 @@ nvmet_fc_remove_port(struct nvmet_port *struct nvmet_fc_tgtport *tgtport =NULL ;unsigned long flags; +mutex_lock (&tgtp_mutex);spin_lock_irqsave (&nvmet_fc_tgtlock, flags);if (pe->tgtport &&nvmet_fc_tgtport_get (pe->tgtport)) tgtport = pe->tgtport;
@@ -2933,6 +2937,7 @@ nvmet_fc_remove_port(struct nvmet_port * }kfree (pe); +mutex_unlock (&tgtp_mutex); } static void
--
syzbot
syzbotsyzbot has tested the proposed patch but the reproducer is still triggering an issue:
Hello,
syzbot has tested the proposed patch but the reproducer is still triggering an issue:
BUG: corrupted list in nvmet_fc_remove_port
non-slab/vmalloc memorylist_del corruption. prev->next should be ffff888042a5f220, but was 0000000000000000. (prev=ffffffff9aecd340)
------------[ cut here ]------------
kernel BUG at lib/list_debug.c:64!
Oops: invalid opcode: 0000 [#1] SMP KASAN PTI
CPU: 0 UID: 0 PID: 6805 Comm: syz.2.84 Not tainted syzkaller #0 PREEMPT_{RT,(full)}
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026
RIP: 0010:__list_del_entry_valid_or_report+0x15a/0x190 lib/list_debug.c:62
Code: e8 8b f8 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 4c bf 58 fd 49 8b 17 48 c7 c7 40 6e cc 8b 48 89 de 4c 89 f9 e8 27 88 4c fc 90 <0f> 0b 4c 89 f7 e8 5c f8 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 1d
RSP: 0000:ffffc90005157c30 EFLAGS: 00010246
RAX: 000000000000006d RBX: ffff888042a5f220 RCX: 112f50d9f18e7400
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000201 R08: 0000000000000000 R09: 0000000000000000
R10: dffffc0000000000 R11: ffffed101708490b R12: 1ffffffff35d9a68
R13: dffffc0000000000 R14: ffffffff85f7e820 R15: ffffffff9aecd340
FS: 00007f076720d6c0(0000) GS:ffff8881249bb000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000564cae572950 CR3: 00000000361dc000 CR4: 00000000003526f0
Call Trace:
<TASK>
__list_del_entry_valid include/linux/list.h:140 [inline]
__list_del_entry include/linux/list.h:261 [inline]
list_del include/linux/list.h:275 [inline]
nvmet_fc_portentry_unbind drivers/nvme/target/fc.c:1281 [inline]
nvmet_fc_remove_port+0x179/0x340 drivers/nvme/target/fc.c:2931
nvmet_disable_port+0x13e/0x1f0 drivers/nvme/target/core.c:400
nvmet_port_subsys_drop_link+0x1e8/0x210 drivers/nvme/target/configfs.c:1123
configfs_unlink+0x44f/0x6b0 fs/configfs/symlink.c:258
vfs_unlink+0x27b/0x6e0 fs/namei.c:5678
filename_unlinkat+0x3d3/0x610 fs/namei.c:5748
__do_sys_unlinkat fs/namei.c:5777 [inline]
__se_sys_unlinkat+0x83/0x1a0 fs/namei.c:5769
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f0767bce1d9
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f076720d028 EFLAGS: 00000246 ORIG_RAX: 0000000000000107
RAX: ffffffffffffffda RBX: 00007f0767e56090 RCX: 00007f0767bce1d9
RDX: 0000000000000000 RSI: 0000200000000780 RDI: ffffffffffffff9c
RBP: 00007f0767c65888 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f0767e56128 R14: 00007f0767e56090 R15: 00007ffc73e653d8
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:__list_del_entry_valid_or_report+0x15a/0x190 lib/list_debug.c:62
Code: e8 8b f8 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 4c bf 58 fd 49 8b 17 48 c7 c7 40 6e cc 8b 48 89 de 4c 89 f9 e8 27 88 4c fc 90 <0f> 0b 4c 89 f7 e8 5c f8 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 1d
RSP: 0000:ffffc90005157c30 EFLAGS: 00010246
RAX: 000000000000006d RBX: ffff888042a5f220 RCX: 112f50d9f18e7400
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000201 R08: 0000000000000000 R09: 0000000000000000
R10: dffffc0000000000 R11: ffffed101708490b R12: 1ffffffff35d9a68
R13: dffffc0000000000 R14: ffffffff85f7e820 R15: ffffffff9aecd340
FS: 00007f076720d6c0(0000) GS:ffff8881249bb000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000564cae572950 CR3: 00000000361dc000 CR4: 00000000003526f0Tested on:
commit: 24a19b95 Linux 7.3-rc7 git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=131aa9c9580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (++20260613092233+e80beda6e255-1~exp1~20260613092250.77), Debian LLD 22.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=10728f15580000
Quoted 5 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview]
Hello,syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
Test Nguyen's idea.
#syz test
drivers/nvme/target/fc.c +3 -2
@@ -1319,12 +1319,13 @@ nvmet_fc_portentry_rebind_tgt(struct nvmspin_lock_irqsave (&nvmet_fc_tgtlock, flags);list_for_each_entry (pe, &nvmet_fc_portentry_list, pe_list) { +if (pe->tgtport) +continue ;if (tgtport->fc_target_port.node_name == pe->node_name && tgtport->fc_target_port.port_name == pe->port_name) {if (!nvmet_fc_tgtport_get (tgtport)) -continue ; +break ; -WARN_ON (pe->tgtport); tgtport->pe = pe; pe->tgtport = tgtport;break ;
--
syzbot
syzbotsyzbot has tested the proposed patch but the reproducer is still triggering an issue:
Hello,
syzbot has tested the proposed patch but the reproducer is still triggering an issue:
BUG: corrupted list in nvmet_fc_remove_port
non-slab/vmalloc memorylist_del corruption. prev->next should be ffff88802b1c4020, but was 0000000000000000. (prev=ffffffff9aecd380)
------------[ cut here ]------------
kernel BUG at lib/list_debug.c:64!
Oops: invalid opcode: 0000 [#1] SMP KASAN PTI
CPU: 1 UID: 0 PID: 6659 Comm: syz.1.38 Not tainted syzkaller #0 PREEMPT_{RT,(full)}
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026
RIP: 0010:__list_del_entry_valid_or_report+0x15a/0x190 lib/list_debug.c:62
Code: e8 fb f0 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 bc b7 58 fd 49 8b 17 48 c7 c7 40 6f cc 8b 48 89 de 4c 89 f9 e8 e7 82 4c fc 90 <0f> 0b 4c 89 f7 e8 cc f0 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 8d
RSP: 0018:ffffc90004f07c30 EFLAGS: 00010246
RAX: 000000000000006d RBX: ffff88802b1c4020 RCX: 1c46e68f21e3c500
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000201 R08: 0000000000000000 R09: 0000000000000000
R10: dffffc0000000000 R11: ffffed10170a490b R12: 1ffffffff35d9a70
R13: dffffc0000000000 R14: ffffffff85f7f100 R15: ffffffff9aecd380
FS: 00007fccc25bd6c0(0000) GS:ffff888124abb000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fbda5aaf000 CR3: 000000002c6f4000 CR4: 00000000003526f0
Call Trace:
<TASK>
__list_del_entry_valid include/linux/list.h:140 [inline]
__list_del_entry include/linux/list.h:261 [inline]
list_del include/linux/list.h:275 [inline]
nvmet_fc_portentry_unbind drivers/nvme/target/fc.c:1281 [inline]
nvmet_fc_remove_port+0x16b/0x320 drivers/nvme/target/fc.c:2928
nvmet_disable_port+0x13e/0x1f0 drivers/nvme/target/core.c:400
nvmet_port_subsys_drop_link+0x1e8/0x210 drivers/nvme/target/configfs.c:1123
configfs_unlink+0x44f/0x6b0 fs/configfs/symlink.c:258
vfs_unlink+0x27b/0x6e0 fs/namei.c:5648
filename_unlinkat+0x3d3/0x610 fs/namei.c:5718
__do_sys_unlinkat fs/namei.c:5747 [inline]
__se_sys_unlinkat+0x83/0x1a0 fs/namei.c:5739
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fccc2f7e1d9
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fccc25bd028 EFLAGS: 00000246 ORIG_RAX: 0000000000000107
RAX: ffffffffffffffda RBX: 00007fccc3206090 RCX: 00007fccc2f7e1d9
RDX: 0000000000000000 RSI: 0000200000000780 RDI: ffffffffffffff9c
RBP: 00007fccc3015888 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fccc3206128 R14: 00007fccc3206090 R15: 00007ffcdc929c08
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:__list_del_entry_valid_or_report+0x15a/0x190 lib/list_debug.c:62
Code: e8 fb f0 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 bc b7 58 fd 49 8b 17 48 c7 c7 40 6f cc 8b 48 89 de 4c 89 f9 e8 e7 82 4c fc 90 <0f> 0b 4c 89 f7 e8 cc f0 37 fd 43 80 3c 2c 00 74 08 4c 89 ff e8 8d
RSP: 0018:ffffc90004f07c30 EFLAGS: 00010246
RAX: 000000000000006d RBX: ffff88802b1c4020 RCX: 1c46e68f21e3c500
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000201 R08: 0000000000000000 R09: 0000000000000000
R10: dffffc0000000000 R11: ffffed10170a490b R12: 1ffffffff35d9a70
R13: dffffc0000000000 R14: ffffffff85f7f100 R15: ffffffff9aecd380
FS: 00007fccc25bd6c0(0000) GS:ffff888124abb000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fbda5aaf000 CR3: 000000002c6f4000 CR4: 00000000003526f0Tested on:
commit: 58161ead Merge tag 'drm-fixes-2026-10-17' of https://g.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=179ce895580000 kernel config: https://syzkaller.appspot.com/x/.config?x=b38d39c45202f4fa dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (1~deb13u4), Debian LLD 22.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=13ea960d580000
Quoted 5 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview]
Hello,syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
#syz test
drivers/nvme/target/fc.c +8 -0
@@ -1271,9 +1271,17 @@ nvmet_fc_portentry_bind(struct nvmet_fc_static void nvmet_fc_portentry_unbind (struct nvmet_fc_port_entry *pe) { +struct nvmet_fc_port_entry *entry;unsigned long flags;spin_lock_irqsave (&nvmet_fc_tgtlock, flags); +list_for_each_entry (entry, &nvmet_fc_portentry_list, pe_list) { +if (entry == pe) + goto out; + } +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags); +return ; +out:if (pe->tgtport) {nvmet_fc_tgtport_put (pe->tgtport); pe->tgtport->pe =NULL ;
--
Quoted 27 lines · Hillf Danton
Quoted 6 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview] Hello,
syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000Test Nguyen's idea.
#syz test
drivers/nvme/target/fc.c +2
-0@@ -1319,12 +1319,13 @@ nvmet_fc_portentry_rebind_tgt(struct nvmspin_lock_irqsave (&nvmet_fc_tgtlock, flags);list_for_each_entry (pe, &nvmet_fc_portentry_list, pe_list) { +if (pe->tgtport) +continue ; if (tgtport->fc_target_port.node_name == pe->node_name &&
drivers/nvme/target/fc.c nvmet_fc_portentry_rebind_tgt(struct nvm
Quoted 10 lines
drivers/nvme/target/fc.c +1
-3tgtport->fc_target_port.port_name == pe->port_name) {if (!nvmet_fc_tgtport_get (tgtport)) -continue ; +break ; -WARN_ON (pe->tgtport); tgtport->pe = pe; pe->tgtport = tgtport;break ; --
[Resending to list + CCs — accidentally dropped them in my previous reply, apologies]
You may need to recheck the commit you're testing
on because #syz test or #syz test: upstream master runs on the latest commit of the repository. Something like #syz test: upstream [commit] would let the bot test it on the specific commit the bug was discovered in.
Best regards,
Nhat Anh
syzbot
syzbotsyzbot has tested the proposed patch but the reproducer is still triggering an issue:
Hello,
syzbot has tested the proposed patch but the reproducer is still triggering an issue:
KASAN: user-memory-access Read in nvmet_fc_tgt_a_get
==================================================================
BUG: KASAN: user-memory-access in instrument_atomic_read include/linux/instrumented.h:82 [inline]
BUG: KASAN: user-memory-access in atomic_read include/linux/atomic/atomic-instrumented.h:32 [inline]
BUG: KASAN: user-memory-access in refcount_read include/linux/refcount.h:170 [inline]
BUG: KASAN: user-memory-access in __refcount_add_not_zero include/linux/refcount.h:176 [inline]
BUG: KASAN: user-memory-access in __refcount_inc_not_zero include/linux/refcount.h:317 [inline]
BUG: KASAN: user-memory-access in refcount_inc_not_zero include/linux/refcount.h:335 [inline]
BUG: KASAN: user-memory-access in kref_get_unless_zero include/linux/kref.h:133 [inline]
BUG: KASAN: user-memory-access in nvmet_fc_tgt_a_get+0x82/0x1d0 drivers/nvme/target/fc.c:1201
Read of size 4 at addr 000000000008c617 by task syz.2.87/6911
CPU: 1 UID: 0 PID: 6911 Comm: syz.2.87 Not tainted syzkaller #0 PREEMPT_{RT,(full)}
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026
Call Trace:
<TASK>
dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120
kasan_report+0x117/0x150 mm/kasan/report.c:595
check_region_inline mm/kasan/generic.c:-1 [inline]
kasan_check_range+0x264/0x2c0 mm/kasan/generic.c:200
instrument_atomic_read include/linux/instrumented.h:82 [inline]
atomic_read include/linux/atomic/atomic-instrumented.h:32 [inline]
refcount_read include/linux/refcount.h:170 [inline]
__refcount_add_not_zero include/linux/refcount.h:176 [inline]
__refcount_inc_not_zero include/linux/refcount.h:317 [inline]
refcount_inc_not_zero include/linux/refcount.h:335 [inline]
kref_get_unless_zero include/linux/kref.h:133 [inline]
nvmet_fc_tgt_a_get+0x82/0x1d0 drivers/nvme/target/fc.c:1201
__nvmet_fc_free_assocs+0x10c/0x380 drivers/nvme/target/fc.c:1488
nvmet_fc_remove_port+0x2a5/0x350 drivers/nvme/target/fc.c:2939
nvmet_disable_port+0x13e/0x1f0 drivers/nvme/target/core.c:400
nvmet_port_subsys_drop_link+0x1e8/0x210 drivers/nvme/target/configfs.c:1123
configfs_unlink+0x44f/0x6b0 fs/configfs/symlink.c:258
vfs_unlink+0x27b/0x6e0 fs/namei.c:5648
filename_unlinkat+0x3d3/0x610 fs/namei.c:5718
__do_sys_unlinkat fs/namei.c:5747 [inline]
__se_sys_unlinkat+0x83/0x1a0 fs/namei.c:5739
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f1994b5e1d9
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f199419d028 EFLAGS: 00000246 ORIG_RAX: 0000000000000107
RAX: ffffffffffffffda RBX: 00007f1994de6090 RCX: 00007f1994b5e1d9
RDX: 0000000000000000 RSI: 0000200000000780 RDI: ffffffffffffff9c
RBP: 00007f1994bf5888 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f1994de6128 R14: 00007f1994de6090 R15: 00007ffcd30e9a38
</TASK>
==================================================================Tested on:
commit: 58161ead Merge tag 'drm-fixes-2026-10-17' of https://g.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=1492efd1580000 kernel config: https://syzkaller.appspot.com/x/.config?x=b38d39c45202f4fa dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (1~deb13u4), Debian LLD 22.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=15d8320d580000
Quoted 5 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview]
Hello,syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
#syz test
drivers/nvme/target/fc.c +12 -0
@@ -1271,9 +1271,17 @@ nvmet_fc_portentry_bind(struct nvmet_fc_static void nvmet_fc_portentry_unbind (struct nvmet_fc_port_entry *pe) { +struct nvmet_fc_port_entry *entry;unsigned long flags;spin_lock_irqsave (&nvmet_fc_tgtlock, flags); +list_for_each_entry (entry, &nvmet_fc_portentry_list, pe_list) { +if (entry == pe) + goto out; + } +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags); +return ; +out:if (pe->tgtport) {nvmet_fc_tgtport_put (pe->tgtport); pe->tgtport->pe =NULL ;
@@ -1643,8 +1651,10 @@ nvmet_fc_unregister_targetport(struct nvnvmet_fc_portentry_unbind_tgt (tgtport); +spin_lock_irqsave (&nvmet_fc_tgtlock, flags);/* terminate any outstanding associations */ __nvmet_fc_free_assocs (tgtport); +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags);flush_workqueue (nvmet_wq);
@@ -2927,8 +2937,10 @@ nvmet_fc_remove_port(struct nvmet_port *nvmet_fc_portentry_unbind (pe);if (tgtport) { +spin_lock_irqsave (&nvmet_fc_tgtlock, flags);/* terminate any outstanding associations */ __nvmet_fc_free_assocs (tgtport); +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags);nvmet_fc_tgtport_put (tgtport); }
--
syzbot
syzbotsyzbot has tested the proposed patch but the reproducer is still triggering an issue:
Hello,
syzbot has tested the proposed patch but the reproducer is still triggering an issue:
KASAN: user-memory-access Read in nvmet_fc_tgt_a_get
==================================================================
BUG: KASAN: user-memory-access in instrument_atomic_read include/linux/instrumented.h:82 [inline]
BUG: KASAN: user-memory-access in atomic_read include/linux/atomic/atomic-instrumented.h:32 [inline]
BUG: KASAN: user-memory-access in refcount_read include/linux/refcount.h:170 [inline]
BUG: KASAN: user-memory-access in __refcount_add_not_zero include/linux/refcount.h:176 [inline]
BUG: KASAN: user-memory-access in __refcount_inc_not_zero include/linux/refcount.h:317 [inline]
BUG: KASAN: user-memory-access in refcount_inc_not_zero include/linux/refcount.h:335 [inline]
BUG: KASAN: user-memory-access in kref_get_unless_zero include/linux/kref.h:133 [inline]
BUG: KASAN: user-memory-access in nvmet_fc_tgt_a_get+0x82/0x1d0 drivers/nvme/target/fc.c:1201
Read of size 4 at addr 000000000008c617 by task syz.2.58/6775
CPU: 1 UID: 0 PID: 6775 Comm: syz.2.58 Not tainted syzkaller #0 PREEMPT_{RT,(full)}
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026
Call Trace:
<TASK>
dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120
kasan_report+0x117/0x150 mm/kasan/report.c:595
check_region_inline mm/kasan/generic.c:-1 [inline]
kasan_check_range+0x264/0x2c0 mm/kasan/generic.c:200
instrument_atomic_read include/linux/instrumented.h:82 [inline]
atomic_read include/linux/atomic/atomic-instrumented.h:32 [inline]
refcount_read include/linux/refcount.h:170 [inline]
__refcount_add_not_zero include/linux/refcount.h:176 [inline]
__refcount_inc_not_zero include/linux/refcount.h:317 [inline]
refcount_inc_not_zero include/linux/refcount.h:335 [inline]
kref_get_unless_zero include/linux/kref.h:133 [inline]
nvmet_fc_tgt_a_get+0x82/0x1d0 drivers/nvme/target/fc.c:1201
__nvmet_fc_free_assocs+0x10c/0x380 drivers/nvme/target/fc.c:1488
nvmet_fc_remove_port+0x2b1/0x360 drivers/nvme/target/fc.c:2942
nvmet_disable_port+0x13e/0x1f0 drivers/nvme/target/core.c:400
nvmet_port_subsys_drop_link+0x1e8/0x210 drivers/nvme/target/configfs.c:1123
configfs_unlink+0x44f/0x6b0 fs/configfs/symlink.c:258
vfs_unlink+0x27b/0x6e0 fs/namei.c:5648
filename_unlinkat+0x3d3/0x610 fs/namei.c:5718
__do_sys_unlinkat fs/namei.c:5747 [inline]
__se_sys_unlinkat+0x83/0x1a0 fs/namei.c:5739
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fedc366e1d9
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fedc2cad028 EFLAGS: 00000246 ORIG_RAX: 0000000000000107
RAX: ffffffffffffffda RBX: 00007fedc38f6090 RCX: 00007fedc366e1d9
RDX: 0000000000000000 RSI: 0000200000000780 RDI: ffffffffffffff9c
RBP: 00007fedc3705888 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fedc38f6128 R14: 00007fedc38f6090 R15: 00007ffd3089d1a8
</TASK>
==================================================================Tested on:
commit: 58161ead Merge tag 'drm-fixes-2026-10-17' of https://g.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=14e66ce1580000 kernel config: https://syzkaller.appspot.com/x/.config?x=b38d39c45202f4fa dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (1~deb13u4), Debian LLD 22.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=175d34e1580000
Quoted 5 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview]
Hello,syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
#syz test
drivers/nvme/target/fc.c +16 -0
@@ -113,6 +113,7 @@ struct nvmet_fc_tgtport {struct nvmet_fc_port_entry *pe;struct kref ref;u32 max_sg_cnt; +int assoc_freed; };struct nvmet_fc_port_entry {
@@ -1271,9 +1272,17 @@ nvmet_fc_portentry_bind(struct nvmet_fc_static void nvmet_fc_portentry_unbind (struct nvmet_fc_port_entry *pe) { +struct nvmet_fc_port_entry *entry;unsigned long flags;spin_lock_irqsave (&nvmet_fc_tgtlock, flags); +list_for_each_entry (entry, &nvmet_fc_portentry_list, pe_list) { +if (entry == pe) + goto out; + } +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags); +return ; +out:if (pe->tgtport) {nvmet_fc_tgtport_put (pe->tgtport); pe->tgtport->pe =NULL ;
@@ -1475,6 +1484,9 @@ __nvmet_fc_free_assocs(struct nvmet_fc_t {struct nvmet_fc_tgt_assoc *assoc; +if (tgtport->assoc_freed) +return ; + tgtport->assoc_freed =1 ;rcu_read_lock ();list_for_each_entry_rcu (assoc, &tgtport->assoc_list, a_list) {if (!nvmet_fc_tgt_a_get (assoc))
@@ -1643,8 +1655,10 @@ nvmet_fc_unregister_targetport(struct nvnvmet_fc_portentry_unbind_tgt (tgtport); +spin_lock_irqsave (&nvmet_fc_tgtlock, flags);/* terminate any outstanding associations */ __nvmet_fc_free_assocs (tgtport); +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags);flush_workqueue (nvmet_wq);
@@ -2927,8 +2941,10 @@ nvmet_fc_remove_port(struct nvmet_port *nvmet_fc_portentry_unbind (pe);if (tgtport) { +spin_lock_irqsave (&nvmet_fc_tgtlock, flags);/* terminate any outstanding associations */ __nvmet_fc_free_assocs (tgtport); +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags);nvmet_fc_tgtport_put (tgtport); }
--
syzbot
syzbotsyzbot has tested the proposed patch but the reproducer is still triggering an issue:
Hello,
syzbot has tested the proposed patch but the reproducer is still triggering an issue:
KASAN: user-memory-access Read in nvmet_fc_tgt_a_get
==================================================================
BUG: KASAN: user-memory-access in instrument_atomic_read include/linux/instrumented.h:82 [inline]
BUG: KASAN: user-memory-access in atomic_read include/linux/atomic/atomic-instrumented.h:32 [inline]
BUG: KASAN: user-memory-access in refcount_read include/linux/refcount.h:170 [inline]
BUG: KASAN: user-memory-access in __refcount_add_not_zero include/linux/refcount.h:176 [inline]
BUG: KASAN: user-memory-access in __refcount_inc_not_zero include/linux/refcount.h:317 [inline]
BUG: KASAN: user-memory-access in refcount_inc_not_zero include/linux/refcount.h:335 [inline]
BUG: KASAN: user-memory-access in kref_get_unless_zero include/linux/kref.h:133 [inline]
BUG: KASAN: user-memory-access in nvmet_fc_tgt_a_get+0x82/0x1d0 drivers/nvme/target/fc.c:1202
Read of size 4 at addr 000000000008c617 by task syz.3.43/6693
CPU: 1 UID: 0 PID: 6693 Comm: syz.3.43 Not tainted syzkaller #0 PREEMPT_{RT,(full)}
Hardware name: Google Goo
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026
Call Trace:
<TASK>
dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120
kasan_report+0x117/0x150 mm/kasan/report.c:595
check_region_inline mm/kasan/generic.c:-1 [inline]
kasan_check_range+0x264/0x2c0 mm/kasan/generic.c:200
instrument_atomic_read include/linux/instrumented.h:82 [inline]
atomic_read include/linux/atomic/atomic-instrumented.h:32 [inline]
refcount_read include/linux/refcount.h:170 [inline]
__refcount_add_not_zero include/linux/refcount.h:176 [inline]
__refcount_inc_not_zero include/linux/refcount.h:317 [inline]
refcount_inc_not_zero include/linux/refcount.h:335 [inline]
kref_get_unless_zero include/linux/kref.h:133 [inline]
nvmet_fc_tgt_a_get+0x82/0x1d0 drivers/nvme/target/fc.c:1202
__nvmet_fc_free_assocs+0x15a/0x410 drivers/nvme/target/fc.c:1492
nvmet_fc_remove_port+0x2b1/0x360 drivers/nvme/target/fc.c:2946
nvmet_disable_port+0x13e/0x1f0 drivers/nvme/target/core.c:400
nvmet_port_subsys_drop_link+0x1e8/0x210 drivers/nvme/target/configfs.c:1123
configfs_unlink+0x44f/0x6b0 fs/configfs/symlink.c:258
vfs_unlink+0x27b/0x6e0 fs/namei.c:5648
filename_unlinkat+0x3d3/0x610 fs/namei.c:5718
__do_sys_unlinkat fs/namei.c:5747 [inline]
__se_sys_unlinkat+0x83/0x1a0 fs/namei.c:5739
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fbccffce1d9
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fbccf60d028 EFLAGS: 00000246 ORIG_RAX: 0000000000000107
RAX: ffffffffffffffda RBX: 00007fbcd0256090 RCX: 00007fbccffce1d9
RDX: 0000000000000000 RSI: 0000200000000780 RDI: ffffffffffffff9c
RBP: 00007fbcd0065888 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fbcd0256128 R14: 00007fbcd0256090 R15: 00007fffd68320f8
</TASK>
==================================================================Tested on:
commit: 58161ead Merge tag 'drm-fixes-2026-10-17' of https://g.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=16ac320d580000 kernel config: https://syzkaller.appspot.com/x/.config?x=b38d39c45202f4fa dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (1~deb13u4), Debian LLD 22.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=15740f01580000
Quoted 5 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview]
Hello,syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
#syz test
drivers/nvme/target/fc.c +19 -0
@@ -113,6 +113,7 @@ struct nvmet_fc_tgtport {struct nvmet_fc_port_entry *pe;struct kref ref;u32 max_sg_cnt; +int assoc_freed; };struct nvmet_fc_port_entry {
@@ -1271,9 +1272,17 @@ nvmet_fc_portentry_bind(struct nvmet_fc_static void nvmet_fc_portentry_unbind (struct nvmet_fc_port_entry *pe) { +struct nvmet_fc_port_entry *entry;unsigned long flags;spin_lock_irqsave (&nvmet_fc_tgtlock, flags); +list_for_each_entry (entry, &nvmet_fc_portentry_list, pe_list) { +if (entry == pe) + goto out; + } +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags); +return ; +out:if (pe->tgtport) {nvmet_fc_tgtport_put (pe->tgtport); pe->tgtport->pe =NULL ;
@@ -1474,14 +1483,20 @@ static void __nvmet_fc_free_assocs(struct nvmet_fc_tgtport *tgtport) {struct nvmet_fc_tgt_assoc *assoc; +unsigned long flags; +if (tgtport->assoc_freed) +return ; + tgtport->assoc_freed =1 ;rcu_read_lock (); +spin_lock_irqsave (&tgtport->lock, flags);list_for_each_entry_rcu (assoc, &tgtport->assoc_list, a_list) {if (!nvmet_fc_tgt_a_get (assoc))continue ;nvmet_fc_schedule_delete_assoc (assoc);nvmet_fc_tgt_a_put (assoc); } +spin_unlock_irqrestore (&tgtport->lock, flags);rcu_read_unlock (); }
@@ -1643,8 +1658,10 @@ nvmet_fc_unregister_targetport(struct nvnvmet_fc_portentry_unbind_tgt (tgtport); +spin_lock_irqsave (&nvmet_fc_tgtlock, flags);/* terminate any outstanding associations */ __nvmet_fc_free_assocs (tgtport); +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags);flush_workqueue (nvmet_wq);
@@ -2927,8 +2944,10 @@ nvmet_fc_remove_port(struct nvmet_port *nvmet_fc_portentry_unbind (pe);if (tgtport) { +spin_lock_irqsave (&nvmet_fc_tgtlock, flags);/* terminate any outstanding associations */ __nvmet_fc_free_assocs (tgtport); +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags);nvmet_fc_tgtport_put (tgtport); }
--
syzbot
syzbotsyzbot has tested the proposed patch but the reproducer is still triggering an issue: INFO: trying to register non-static key in __nvmet_fc_free_assocs
Hello,
syzbot has tested the proposed patch but the reproducer is still triggering an issue:
INFO: trying to register non-static key in __nvmet_fc_free_assocs
INFO: trying to register non-static key.
The code is fine but needs lockdep annotation, or maybe you didn't initialize this object before use? turning off the locking correctness validator.
CPU: 0 UID: 0 PID: 6854 Comm: syz.0.124 Not tainted syzkaller #0 PREEMPT_{RT,(full)}
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026
Call Trace:
<TASK>
dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120
assign_lock_key+0x133/0x150 kernel/locking/lockdep.c:1028
register_lock_class+0xcc/0x2e0 kernel/locking/lockdep.c:1343
__lock_acquire+0x10c/0x2de0 kernel/locking/lockdep.c:5162
lock_acquire+0x115/0x350 kernel/locking/lockdep.c:5942
rt_spin_lock+0x83/0x400 kernel/locking/spinlock_rt.c:56
spin_lock include/linux/spinlock_rt.h:45 [inline]
__nvmet_fc_free_assocs+0x12e/0x430 drivers/nvme/target/fc.c:1492
nvmet_fc_remove_port+0x2b1/0x360 drivers/nvme/target/fc.c:2949
nvmet_disable_port+0x13e/0x1f0 drivers/nvme/target/core.c:400
nvmet_port_subsys_drop_link+0x1e8/0x210 drivers/nvme/target/configfs.c:1123
configfs_unlink+0x44f/0x6b0 fs/configfs/symlink.c:258
vfs_unlink+0x27b/0x6e0 fs/namei.c:5648
filename_unlinkat+0x3d3/0x610 fs/namei.c:5718
__do_sys_unlinkat fs/namei.c:5747 [inline]
__se_sys_unlinkat+0x83/0x1a0 fs/namei.c:5739
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f94beb6e1d9
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f94be1ad028 EFLAGS: 00000246 ORIG_RAX: 0000000000000107
RAX: ffffffffffffffda RBX: 00007f94bedf6090 RCX: 00007f94beb6e1d9
RDX: 0000000000000000 RSI: 0000200000000780 RDI: ffffffffffffff9c
RBP: 00007f94bec05888 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f94bedf6128 R14: 00007f94bedf6090 R15: 00007ffc099f6dd8
</TASK>
------------[ cut here ]------------
UBSAN: array-index-out-of-bounds in kernel/locking/qspinlock.h:68:9
index 16382 is out of range for type 'unsigned long[8]'
CPU: 0 UID: 0 PID: 6854 Comm: syz.0.124 Not tainted syzkaller #0 PREEMPT_{RT,(full)}
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/07/2026
Call Trace:
<TASK>
dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120
ubsan_epilogue+0xa/0x30 lib/ubsan.c:233
__ubsan_handle_out_of_bounds+0xe8/0xf0 lib/ubsan.c:455
decode_tail kernel/locking/qspinlock.h:68 [inline]
__pv_queued_spin_lock_slowpath+0xaf3/0xbc0 kernel/locking/qspinlock.c:307
pv_queued_spin_lock_slowpath arch/x86/include/asm/paravirt-spinlock.h:37 [inline]
queued_spin_lock_slowpath arch/x86/include/asm/paravirt-spinlock.h:71 [inline]
queued_spin_lock include/asm-generic/qspinlock.h:115 [inline]
do_raw_spin_lock+0x26c/0x2f0 kernel/locking/spinlock_debug.c:116
__raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:156 [inline]
_raw_spin_lock_irqsave+0x4c/0x60 kernel/locking/spinlock.c:181
rtlock_slowlock kernel/locking/rtmutex.c:1921 [inline]
rtlock_lock kernel/locking/spinlock_rt.c:43 [inline]
__rt_spin_lock kernel/locking/spinlock_rt.c:49 [inline]
rt_spin_lock+0x157/0x400 kernel/locking/spinlock_rt.c:57
spin_lock include/linux/spinlock_rt.h:45 [inline]
__nvmet_fc_free_assocs+0x12e/0x430 drivers/nvme/target/fc.c:1492
nvmet_fc_remove_port+0x2b1/0x360 drivers/nvme/target/fc.c:2949
nvmet_disable_port+0x13e/0x1f0 drivers/nvme/target/core.c:400
nvmet_port_subsys_drop_link+0x1e8/0x210 drivers/nvme/target/configfs.c:1123
configfs_unlink+0x44f/0x6b0 fs/configfs/symlink.c:258
vfs_unlink+0x27b/0x6e0 fs/namei.c:5648
filename_unlinkat+0x3d3/0x610 fs/namei.c:5718
__do_sys_unlinkat fs/namei.c:5747 [inline]
__se_sys_unlinkat+0x83/0x1a0 fs/namei.c:5739
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f94beb6e1d9
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f94be1ad028 EFLAGS: 00000246 ORIG_RAX: 0000000000000107
RAX: ffffffffffffffda RBX: 00007f94bedf6090 RCX: 00007f94beb6e1d9
RDX: 0000000000000000 RSI: 0000200000000780 RDI: ffffffffffffff9c
RBP: 00007f94bec05888 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f94bedf6128 R14: 00007f94bedf6090 R15: 00007ffc099f6dd8
</TASK>
---[ end trace ]---Tested on:
commit: 58161ead Merge tag 'drm-fixes-2026-10-17' of https://g.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=10d88031580000 kernel config: https://syzkaller.appspot.com/x/.config?x=b38d39c45202f4fa dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (1~deb13u4), Debian LLD 22.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=16d7f67f980000
Quoted 5 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview]
Hello,syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
#syz test
drivers/nvme/target/fc.c +22 -2
@@ -113,6 +113,7 @@ struct nvmet_fc_tgtport {struct nvmet_fc_port_entry *pe;struct kref ref;u32 max_sg_cnt; +int assoc_freed; };struct nvmet_fc_port_entry {
@@ -1271,9 +1272,17 @@ nvmet_fc_portentry_bind(struct nvmet_fc_static void nvmet_fc_portentry_unbind (struct nvmet_fc_port_entry *pe) { +struct nvmet_fc_port_entry *entry;unsigned long flags;spin_lock_irqsave (&nvmet_fc_tgtlock, flags); +list_for_each_entry (entry, &nvmet_fc_portentry_list, pe_list) { +if (entry == pe) + goto out; + } +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags); +return ; +out:if (pe->tgtport) {nvmet_fc_tgtport_put (pe->tgtport); pe->tgtport->pe =NULL ;
@@ -1414,7 +1423,7 @@ nvmet_fc_register_targetport(struct nvme goto out_free_newrec; } -nvmet_fc_portentry_rebind_tgt (newrec); +//nvmet_fc_portentry_rebind_tgt(newrec); spin_lock_irqsave (&nvmet_fc_tgtlock, flags);list_add_tail (&newrec->tgt_list, &nvmet_fc_target_list);
@@ -1474,14 +1483,20 @@ static void __nvmet_fc_free_assocs(struct nvmet_fc_tgtport *tgtport) {struct nvmet_fc_tgt_assoc *assoc; +unsigned long flags; +if (tgtport->assoc_freed) +return ; + tgtport->assoc_freed =1 ;rcu_read_lock (); +spin_lock_irqsave (&tgtport->lock, flags);list_for_each_entry_rcu (assoc, &tgtport->assoc_list, a_list) {if (!nvmet_fc_tgt_a_get (assoc))continue ;nvmet_fc_schedule_delete_assoc (assoc);nvmet_fc_tgt_a_put (assoc); } +spin_unlock_irqrestore (&tgtport->lock, flags);rcu_read_unlock (); }
@@ -1643,8 +1658,10 @@ nvmet_fc_unregister_targetport(struct nvnvmet_fc_portentry_unbind_tgt (tgtport); +spin_lock_irqsave (&nvmet_fc_tgtlock, flags);/* terminate any outstanding associations */ __nvmet_fc_free_assocs (tgtport); +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags);flush_workqueue (nvmet_wq);
@@ -2917,6 +2934,7 @@ nvmet_fc_remove_port(struct nvmet_port * {struct nvmet_fc_port_entry *pe = port->priv;struct nvmet_fc_tgtport *tgtport =NULL ; +struct nvmet_fc_tgtport *next =NULL ;unsigned long flags;spin_lock_irqsave (&nvmet_fc_tgtlock, flags);
@@ -2926,9 +2944,11 @@ nvmet_fc_remove_port(struct nvmet_port *nvmet_fc_portentry_unbind (pe); -if (tgtport) { +if (tgtport && next) { +spin_lock_irqsave (&nvmet_fc_tgtlock, flags);/* terminate any outstanding associations */ __nvmet_fc_free_assocs (tgtport); +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags);nvmet_fc_tgtport_put (tgtport); }
--
syzbot has tested the proposed patch and the reproducer did not trigger any issue:
Hello,
syzbot has tested the proposed patch and the reproducer did not trigger any issue:
Tested on:
commit: 58161ead Merge tag 'drm-fixes-2026-10-17' of https://g.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=1760560d580000 kernel config: https://syzkaller.appspot.com/x/.config?x=b38d39c45202f4fa dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (1~deb13u4), Debian LLD 22.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=10ad8121580000
Note: testing is done by a robot and is best-effort only.
Quoted 5 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview]
Hello,syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
#syz test
drivers/nvme/target/fc.c +21 -1
@@ -113,6 +113,7 @@ struct nvmet_fc_tgtport {struct nvmet_fc_port_entry *pe;struct kref ref;u32 max_sg_cnt; +int assoc_freed; };struct nvmet_fc_port_entry {
@@ -1271,9 +1272,17 @@ nvmet_fc_portentry_bind(struct nvmet_fc_static void nvmet_fc_portentry_unbind (struct nvmet_fc_port_entry *pe) { +struct nvmet_fc_port_entry *entry;unsigned long flags;spin_lock_irqsave (&nvmet_fc_tgtlock, flags); +list_for_each_entry (entry, &nvmet_fc_portentry_list, pe_list) { +if (entry == pe) + goto out; + } +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags); +return ; +out:if (pe->tgtport) {nvmet_fc_tgtport_put (pe->tgtport); pe->tgtport->pe =NULL ;
@@ -1474,14 +1483,20 @@ static void __nvmet_fc_free_assocs(struct nvmet_fc_tgtport *tgtport) {struct nvmet_fc_tgt_assoc *assoc; +unsigned long flags; +if (tgtport->assoc_freed) +return ; + tgtport->assoc_freed =1 ;rcu_read_lock (); +spin_lock_irqsave (&tgtport->lock, flags);list_for_each_entry_rcu (assoc, &tgtport->assoc_list, a_list) {if (!nvmet_fc_tgt_a_get (assoc))continue ;nvmet_fc_schedule_delete_assoc (assoc);nvmet_fc_tgt_a_put (assoc); } +spin_unlock_irqrestore (&tgtport->lock, flags);rcu_read_unlock (); }
@@ -1643,8 +1658,10 @@ nvmet_fc_unregister_targetport(struct nvnvmet_fc_portentry_unbind_tgt (tgtport); +spin_lock_irqsave (&nvmet_fc_tgtlock, flags);/* terminate any outstanding associations */ __nvmet_fc_free_assocs (tgtport); +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags);flush_workqueue (nvmet_wq);
@@ -2917,6 +2934,7 @@ nvmet_fc_remove_port(struct nvmet_port * {struct nvmet_fc_port_entry *pe = port->priv;struct nvmet_fc_tgtport *tgtport =NULL ; +struct nvmet_fc_tgtport *next =NULL ;unsigned long flags;spin_lock_irqsave (&nvmet_fc_tgtlock, flags);
@@ -2926,9 +2944,11 @@ nvmet_fc_remove_port(struct nvmet_port *nvmet_fc_portentry_unbind (pe); -if (tgtport) { +if (tgtport && next) { +spin_lock_irqsave (&nvmet_fc_tgtlock, flags);/* terminate any outstanding associations */ __nvmet_fc_free_assocs (tgtport); +spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags);nvmet_fc_tgtport_put (tgtport); }
--
syzbot has tested the proposed patch and the reproducer did not trigger any issue:
Hello,
syzbot has tested the proposed patch and the reproducer did not trigger any issue:
Tested on:
commit: 58161ead Merge tag 'drm-fixes-2026-10-17' of https://g.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=13a8dda9580000 kernel config: https://syzkaller.appspot.com/x/.config?x=b38d39c45202f4fa dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (1~deb13u4), Debian LLD 22.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=1286b4e1580000
Note: testing is done by a robot and is best-effort only.
Quoted 5 lines
Date: Sun, 11 Oct 2026 10:32:37 -0700 [thread overview]
Hello,syzbot found the following issue on:
Quoted 7 lines
HEAD commit: a5ebb76233b7 Merge tag 'edac_urgent_for_v7.3_rc7' of git:/.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1494923e580000 kernel config: https://syzkaller.appspot.com/x/.config?x=df4bbab1c2172b9f dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a syz repro: https://syzkaller.appspot.com/x/repro.syz?x=126a0f15580000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=166a0f15580000
#syz test
drivers/nvme/target/fc.c +16 -23
@@ -1268,20 +1268,6 @@ nvmet_fc_portentry_bind(struct nvmet_fc_list_add_tail (&pe->pe_list, &nvmet_fc_portentry_list); } -static void -nvmet_fc_portentry_unbind (struct nvmet_fc_port_entry *pe) -{ -unsigned long flags; - -spin_lock_irqsave (&nvmet_fc_tgtlock, flags); -if (pe->tgtport) { -nvmet_fc_tgtport_put (pe->tgtport); - pe->tgtport->pe =NULL ; - } -list_del (&pe->pe_list); -spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags); -} -/* * called when a targetport deregisters. Breaks the relationship * with the nvmet port, but leaves the port_entry in place so that
@@ -2915,24 +2901,31 @@ nvmet_fc_add_port(struct nvmet_port *porstatic void nvmet_fc_remove_port (struct nvmet_port *port) { -struct nvmet_fc_port_entry *pe = port->priv; +struct nvmet_fc_port_entry *pe, *entry, *an =NULL ;struct nvmet_fc_tgtport *tgtport =NULL ;unsigned long flags;spin_lock_irqsave (&nvmet_fc_tgtlock, flags); -if (pe->tgtport &&nvmet_fc_tgtport_get (pe->tgtport)) - tgtport = pe->tgtport; + pe = port->priv; +list_for_each_entry (entry, &nvmet_fc_portentry_list, pe_list) { +if (!pe) +break ; +if (entry != pe) +continue ; +list_del (&pe->pe_list); +if (pe->tgtport) { + pe->tgtport->pe =NULL ; + tgtport = pe->tgtport; + } + an = pe; +break ; + }spin_unlock_irqrestore (&nvmet_fc_tgtlock, flags); -nvmet_fc_portentry_unbind (pe); - +kfree (an);if (tgtport) { -/* terminate any outstanding associations */ -__nvmet_fc_free_assocs (tgtport);nvmet_fc_tgtport_put (tgtport); } - -kfree (pe); } static void
--
syzbot has tested the proposed patch and the reproducer did not trigger any issue:
Hello,
syzbot has tested the proposed patch and the reproducer did not trigger any issue:
Tested on:
commit: 32c52ec8 x86/insn-eval: Fix shadowed segment index in .. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=116f8121580000 kernel config: https://syzkaller.appspot.com/x/.config?x=b38d39c45202f4fa dashboard link: https://syzkaller.appspot.com/bug?extid=c98b21427617af7f547a compiler: Debian clang version 22.1.8 (1~deb13u4), Debian LLD 22.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=125cdda9580000
Note: testing is done by a robot and is best-effort only.