Extracting prog: 1m8.128054601s
Minimizing prog: 4m20.269663911s
Simplifying prog options: 2m6.221879757s
Extracting C: 20.931970752s
Simplifying C: 0s
extracting reproducer from 1 programs
testing a last program of every proc
single: executing 1 programs separately with timeout 30s
testing program (duration=30s, {Threaded:true Repeat:true RepeatTimes:0 Procs:4 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program crashed: possible deadlock in rds_trans_get_preferred
single: successfully extracted reproducer
found reproducer with 4 syscalls
minimizing guilty program
testing program (duration=30s, {Threaded:true Repeat:true RepeatTimes:0 Procs:4 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
program did not crash
testing program (duration=30s, {Threaded:true Repeat:true RepeatTimes:0 Procs:4 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program did not crash
testing program (duration=30s, {Threaded:true Repeat:true RepeatTimes:0 Procs:4 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
bind$rds(0xffffffffffffffff, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(0xffffffffffffffff, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program did not crash
testing program (duration=30s, {Threaded:true Repeat:true RepeatTimes:0 Procs:4 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program did not crash
testing program (duration=30s, {Threaded:true Repeat:true RepeatTimes:0 Procs:4 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, 0x0, 0x0)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program did not crash
testing program (duration=30s, {Threaded:true Repeat:true RepeatTimes:0 Procs:4 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, 0x0, 0x0)
program did not crash
testing program (duration=30s, {Threaded:true Repeat:true RepeatTimes:0 Procs:4 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={0x0, 0x0, 0x0}, 0x0)
program did not crash
extracting C reproducer
testing compiled C program (duration=30s, {Threaded:true Repeat:true RepeatTimes:0 Procs:4 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
program did not crash
simplifying guilty program options
testing program (duration=30s, {Threaded:false Repeat:true RepeatTimes:0 Procs:4 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program crashed: possible deadlock in rds_trans_get_preferred
extracting C reproducer
testing compiled C program (duration=30s, {Threaded:false Repeat:true RepeatTimes:0 Procs:4 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
program did not crash
testing program (duration=30s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program crashed: possible deadlock in rds_trans_get_preferred
extracting C reproducer
testing compiled C program (duration=30s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
program did not crash
testing program (duration=30s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program crashed: possible deadlock in rds_trans_get_preferred
validation run: crashed=true
testing program (duration=30s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program crashed: possible deadlock in rds_trans_get_preferred
validation run: crashed=true
testing program (duration=30s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program did not crash
validation run: crashed=false
testing program (duration=30s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program did not crash
validation run: crashed=false
testing program (duration=30s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program did not crash
validation run: crashed=false
testing program (duration=30s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program did not crash
validation run: crashed=false
testing program (duration=30s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program did not crash
validation run: crashed=false
testing program (duration=30s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program did not crash
validation run: crashed=false
testing program (duration=30s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program did not crash
validation run: crashed=false
testing program (duration=30s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false CallComments:true LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setns-socket$rds-bind$rds-sendmsg$rds
detailed listing:
executing program 0:
setns(0xc9, 0x0)
r0 = socket$rds(0x15, 0x5, 0x0)
bind$rds(r0, &(0x7f0000000300)={0x2, 0x4e21, @local}, 0x10)
sendmsg$rds(r0, &(0x7f0000000340)={&(0x7f0000000480)={0x2, 0x4e21, @local}, 0x10, 0x0}, 0x0)
program crashed: possible deadlock in rds_trans_get_preferred
validation run: crashed=true
reproducing took 17m48.676033602s
repro crashed as (corrupted=false):
======================================================
WARNING: possible circular locking dependency detected
syzkaller #0 Not tainted
------------------------------------------------------
kworker/0:2/859 is trying to acquire lock:
ffffffff922a86c8 (rds_trans_sem){++++}-{4:4}, at: rds_trans_get_preferred+0xf7/0x2c0 net/rds/transport.c:100
but task is already holding lock:
ffff88802f105420 (&id_priv->handler_mutex/1){+.+.}-{4:4}, at: cma_ib_req_handler+0x16ff/0x5700 drivers/infiniband/core/cma.c:2450
which lock already depends on the new lock.
the existing dependency chain (in reverse order) is:
-> #2 (&id_priv->handler_mutex/1){+.+.}-{4:4}:
lock_acquire kernel/locking/lockdep.c:5942 [inline]
lock_acquire+0x1d1/0x380 kernel/locking/lockdep.c:5899
__mutex_lock_common kernel/locking/mutex.c:646 [inline]
__mutex_lock+0x19f/0x1c10 kernel/locking/mutex.c:821
cma_ib_req_handler+0x16ff/0x5700 drivers/infiniband/core/cma.c:2450
cm_process_work+0x46/0x440 drivers/infiniband/core/cm.c:1869
cm_queue_work_unlock+0x5d/0x250 drivers/infiniband/core/cm.c:933
cm_req_handler drivers/infiniband/core/cm.c:2235 [inline]
cm_work_handler+0x638d/0xc860 drivers/infiniband/core/cm.c:3849
process_one_work+0xac7/0x1b10 kernel/workqueue.c:3495
process_scheduled_works kernel/workqueue.c:3578 [inline]
worker_thread+0x5ef/0xe50 kernel/workqueue.c:3659
kthread+0x373/0x450 kernel/kthread.c:436
ret_from_fork+0x730/0xd60 arch/x86/kernel/process.c:158
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245
-> #1 (&id_priv->handler_mutex){+.+.}-{4:4}:
lock_acquire kernel/locking/lockdep.c:5942 [inline]
lock_acquire+0x1d1/0x380 kernel/locking/lockdep.c:5899
__mutex_lock_common kernel/locking/mutex.c:646 [inline]
__mutex_lock+0x19f/0x1c10 kernel/locking/mutex.c:821
rdma_destroy_id+0x1b/0x30 drivers/infiniband/core/cma.c:2124
rds_ib_laddr_check_cm net/rds/ib.c:487 [inline]
rds_ib_laddr_check+0x2cb/0x660 net/rds/ib.c:509
rds_trans_get_preferred+0x15f/0x2c0 net/rds/transport.c:104
rds_bind+0x17fe/0x2440 net/rds/bind.c:254
__sys_bind_socket net/socket.c:1947 [inline]
__sys_bind_socket net/socket.c:1939 [inline]
__sys_bind+0x1a9/0x260 net/socket.c:1978
__do_sys_bind net/socket.c:1983 [inline]
__se_sys_bind net/socket.c:1981 [inline]
__x64_sys_bind+0x72/0xb0 net/socket.c:1981
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x123/0x790 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
-> #0 (rds_trans_sem){++++}-{4:4}:
check_prev_add+0xeb/0xe60 kernel/locking/lockdep.c:3209
check_prevs_add kernel/locking/lockdep.c:3328 [inline]
validate_chain kernel/locking/lockdep.c:3952 [inline]
__lock_acquire+0x1528/0x1f40 kernel/locking/lockdep.c:5288
lock_acquire kernel/locking/lockdep.c:5942 [inline]
lock_acquire+0x1d1/0x380 kernel/locking/lockdep.c:5899
down_read+0x94/0x4c0 kernel/locking/rwsem.c:1574
rds_trans_get_preferred+0xf7/0x2c0 net/rds/transport.c:100
__rds_conn_create+0xad5/0x2650 net/rds/connection.c:252
rds_conn_create+0x44/0x60 net/rds/connection.c:384
rds_ib_cm_handle_connect+0x62b/0x1220 net/rds/ib_cm.c:860
rds_rdma_cm_event_handler_cmn+0x59f/0x9b0 net/rds/rdma_transport.c:91
cma_listen_handler+0x11a/0x180 drivers/infiniband/core/cma.c:2716
cma_cm_event_handler+0x99/0x300 drivers/infiniband/core/cma.c:2181
cma_ib_req_handler+0x1be2/0x5700 drivers/infiniband/core/cma.c:2461
cm_process_work+0x46/0x440 drivers/infiniband/core/cm.c:1869
cm_queue_work_unlock+0x5d/0x250 drivers/infiniband/core/cm.c:933
cm_req_handler drivers/infiniband/core/cm.c:2235 [inline]
cm_work_handler+0x638d/0xc860 drivers/infiniband/core/cm.c:3849
process_one_work+0xac7/0x1b10 kernel/workqueue.c:3495
process_scheduled_works kernel/workqueue.c:3578 [inline]
worker_thread+0x5ef/0xe50 kernel/workqueue.c:3659
kthread+0x373/0x450 kernel/kthread.c:436
ret_from_fork+0x730/0xd60 arch/x86/kernel/process.c:158
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245
other info that might help us debug this:
Chain exists of:
rds_trans_sem --> &id_priv->handler_mutex --> &id_priv->handler_mutex/1
Possible unsafe locking scenario:
CPU0 CPU1
---- ----
lock(&id_priv->handler_mutex/1);
lock(&id_priv->handler_mutex);
lock(&id_priv->handler_mutex/1);
rlock(rds_trans_sem);
*** DEADLOCK ***
locks held by kworker/0:2/859: 4, last CPU#0:
#0: ffff888034cfa148 ((wq_completion)ib_cm){+.+.}-{0:0}, at: process_one_work+0x1461/0x1b10 kernel/workqueue.c:3470
#1: ffffc90004bb7d08 ((work_completion)(&(&work->work)->work)){+.+.}-{0:0}, at: process_one_work+0xa2c/0x1b10 kernel/workqueue.c:3471
#2: ffff888035421420 (&id_priv->handler_mutex){+.+.}-{4:4}, at: cma_ib_req_handler+0xef1/0x5700 drivers/infiniband/core/cma.c:2427
#3: ffff88802f105420 (&id_priv->handler_mutex/1){+.+.}-{4:4}, at: cma_ib_req_handler+0x16ff/0x5700 drivers/infiniband/core/cma.c:2450
stack backtrace:
CPU: 0 UID: 0 PID: 859 Comm: kworker/0:2 Not tainted syzkaller #0 PREEMPT(full)
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
Workqueue: ib_cm cm_work_handler
Call Trace:
__dump_stack lib/dump_stack.c:94 [inline]
dump_stack_lvl+0x100/0x190 lib/dump_stack.c:120
print_circular_bug.cold+0x178/0x1be kernel/locking/lockdep.c:2087
check_noncircular+0x146/0x160 kernel/locking/lockdep.c:2219
check_prev_add+0xeb/0xe60 kernel/locking/lockdep.c:3209
check_prevs_add kernel/locking/lockdep.c:3328 [inline]
validate_chain kernel/locking/lockdep.c:3952 [inline]
__lock_acquire+0x1528/0x1f40 kernel/locking/lockdep.c:5288
lock_acquire kernel/locking/lockdep.c:5942 [inline]
lock_acquire+0x1d1/0x380 kernel/locking/lockdep.c:5899
down_read+0x94/0x4c0 kernel/locking/rwsem.c:1574
rds_trans_get_preferred+0xf7/0x2c0 net/rds/transport.c:100
__rds_conn_create+0xad5/0x2650 net/rds/connection.c:252
rds_conn_create+0x44/0x60 net/rds/connection.c:384
rds_ib_cm_handle_connect+0x62b/0x1220 net/rds/ib_cm.c:860
rds_rdma_cm_event_handler_cmn+0x59f/0x9b0 net/rds/rdma_transport.c:91
cma_listen_handler+0x11a/0x180 drivers/infiniband/core/cma.c:2716
cma_cm_event_handler+0x99/0x300 drivers/infiniband/core/cma.c:2181
cma_ib_req_handler+0x1be2/0x5700 drivers/infiniband/core/cma.c:2461
cm_process_work+0x46/0x440 drivers/infiniband/core/cm.c:1869
cm_queue_work_unlock+0x5d/0x250 drivers/infiniband/core/cm.c:933
cm_req_handler drivers/infiniband/core/cm.c:2235 [inline]
cm_work_handler+0x638d/0xc860 drivers/infiniband/core/cm.c:3849
process_one_work+0xac7/0x1b10 kernel/workqueue.c:3495
process_scheduled_works kernel/workqueue.c:3578 [inline]
worker_thread+0x5ef/0xe50 kernel/workqueue.c:3659
kthread+0x373/0x450 kernel/kthread.c:436
ret_from_fork+0x730/0xd60 arch/x86/kernel/process.c:158
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245
RDS/IB: Active conn connected <::ffff:172.20.20.170,::ffff:172.20.20.170,0> version 3.1
RDS/IB: Passive conn connected <::ffff:172.20.20.170,::ffff:172.20.20.170,0> version 3.1
final repro crashed as (corrupted=false):
======================================================
WARNING: possible circular locking dependency detected
syzkaller #0 Not tainted
------------------------------------------------------
kworker/0:2/859 is trying to acquire lock:
ffffffff922a86c8 (rds_trans_sem){++++}-{4:4}, at: rds_trans_get_preferred+0xf7/0x2c0 net/rds/transport.c:100
but task is already holding lock:
ffff88802f105420 (&id_priv->handler_mutex/1){+.+.}-{4:4}, at: cma_ib_req_handler+0x16ff/0x5700 drivers/infiniband/core/cma.c:2450
which lock already depends on the new lock.
the existing dependency chain (in reverse order) is:
-> #2 (&id_priv->handler_mutex/1){+.+.}-{4:4}:
lock_acquire kernel/locking/lockdep.c:5942 [inline]
lock_acquire+0x1d1/0x380 kernel/locking/lockdep.c:5899
__mutex_lock_common kernel/locking/mutex.c:646 [inline]
__mutex_lock+0x19f/0x1c10 kernel/locking/mutex.c:821
cma_ib_req_handler+0x16ff/0x5700 drivers/infiniband/core/cma.c:2450
cm_process_work+0x46/0x440 drivers/infiniband/core/cm.c:1869
cm_queue_work_unlock+0x5d/0x250 drivers/infiniband/core/cm.c:933
cm_req_handler drivers/infiniband/core/cm.c:2235 [inline]
cm_work_handler+0x638d/0xc860 drivers/infiniband/core/cm.c:3849
process_one_work+0xac7/0x1b10 kernel/workqueue.c:3495
process_scheduled_works kernel/workqueue.c:3578 [inline]
worker_thread+0x5ef/0xe50 kernel/workqueue.c:3659
kthread+0x373/0x450 kernel/kthread.c:436
ret_from_fork+0x730/0xd60 arch/x86/kernel/process.c:158
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245
-> #1 (&id_priv->handler_mutex){+.+.}-{4:4}:
lock_acquire kernel/locking/lockdep.c:5942 [inline]
lock_acquire+0x1d1/0x380 kernel/locking/lockdep.c:5899
__mutex_lock_common kernel/locking/mutex.c:646 [inline]
__mutex_lock+0x19f/0x1c10 kernel/locking/mutex.c:821
rdma_destroy_id+0x1b/0x30 drivers/infiniband/core/cma.c:2124
rds_ib_laddr_check_cm net/rds/ib.c:487 [inline]
rds_ib_laddr_check+0x2cb/0x660 net/rds/ib.c:509
rds_trans_get_preferred+0x15f/0x2c0 net/rds/transport.c:104
rds_bind+0x17fe/0x2440 net/rds/bind.c:254
__sys_bind_socket net/socket.c:1947 [inline]
__sys_bind_socket net/socket.c:1939 [inline]
__sys_bind+0x1a9/0x260 net/socket.c:1978
__do_sys_bind net/socket.c:1983 [inline]
__se_sys_bind net/socket.c:1981 [inline]
__x64_sys_bind+0x72/0xb0 net/socket.c:1981
do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
do_syscall_64+0x123/0x790 arch/x86/entry/syscall_64.c:84
entry_SYSCALL_64_after_hwframe+0x77/0x7f
-> #0 (rds_trans_sem){++++}-{4:4}:
check_prev_add+0xeb/0xe60 kernel/locking/lockdep.c:3209
check_prevs_add kernel/locking/lockdep.c:3328 [inline]
validate_chain kernel/locking/lockdep.c:3952 [inline]
__lock_acquire+0x1528/0x1f40 kernel/locking/lockdep.c:5288
lock_acquire kernel/locking/lockdep.c:5942 [inline]
lock_acquire+0x1d1/0x380 kernel/locking/lockdep.c:5899
down_read+0x94/0x4c0 kernel/locking/rwsem.c:1574
rds_trans_get_preferred+0xf7/0x2c0 net/rds/transport.c:100
__rds_conn_create+0xad5/0x2650 net/rds/connection.c:252
rds_conn_create+0x44/0x60 net/rds/connection.c:384
rds_ib_cm_handle_connect+0x62b/0x1220 net/rds/ib_cm.c:860
rds_rdma_cm_event_handler_cmn+0x59f/0x9b0 net/rds/rdma_transport.c:91
cma_listen_handler+0x11a/0x180 drivers/infiniband/core/cma.c:2716
cma_cm_event_handler+0x99/0x300 drivers/infiniband/core/cma.c:2181
cma_ib_req_handler+0x1be2/0x5700 drivers/infiniband/core/cma.c:2461
cm_process_work+0x46/0x440 drivers/infiniband/core/cm.c:1869
cm_queue_work_unlock+0x5d/0x250 drivers/infiniband/core/cm.c:933
cm_req_handler drivers/infiniband/core/cm.c:2235 [inline]
cm_work_handler+0x638d/0xc860 drivers/infiniband/core/cm.c:3849
process_one_work+0xac7/0x1b10 kernel/workqueue.c:3495
process_scheduled_works kernel/workqueue.c:3578 [inline]
worker_thread+0x5ef/0xe50 kernel/workqueue.c:3659
kthread+0x373/0x450 kernel/kthread.c:436
ret_from_fork+0x730/0xd60 arch/x86/kernel/process.c:158
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245
other info that might help us debug this:
Chain exists of:
rds_trans_sem --> &id_priv->handler_mutex --> &id_priv->handler_mutex/1
Possible unsafe locking scenario:
CPU0 CPU1
---- ----
lock(&id_priv->handler_mutex/1);
lock(&id_priv->handler_mutex);
lock(&id_priv->handler_mutex/1);
rlock(rds_trans_sem);
*** DEADLOCK ***
locks held by kworker/0:2/859: 4, last CPU#0:
#0: ffff888034cfa148 ((wq_completion)ib_cm){+.+.}-{0:0}, at: process_one_work+0x1461/0x1b10 kernel/workqueue.c:3470
#1: ffffc90004bb7d08 ((work_completion)(&(&work->work)->work)){+.+.}-{0:0}, at: process_one_work+0xa2c/0x1b10 kernel/workqueue.c:3471
#2: ffff888035421420 (&id_priv->handler_mutex){+.+.}-{4:4}, at: cma_ib_req_handler+0xef1/0x5700 drivers/infiniband/core/cma.c:2427
#3: ffff88802f105420 (&id_priv->handler_mutex/1){+.+.}-{4:4}, at: cma_ib_req_handler+0x16ff/0x5700 drivers/infiniband/core/cma.c:2450
stack backtrace:
CPU: 0 UID: 0 PID: 859 Comm: kworker/0:2 Not tainted syzkaller #0 PREEMPT(full)
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
Workqueue: ib_cm cm_work_handler
Call Trace:
__dump_stack lib/dump_stack.c:94 [inline]
dump_stack_lvl+0x100/0x190 lib/dump_stack.c:120
print_circular_bug.cold+0x178/0x1be kernel/locking/lockdep.c:2087
check_noncircular+0x146/0x160 kernel/locking/lockdep.c:2219
check_prev_add+0xeb/0xe60 kernel/locking/lockdep.c:3209
check_prevs_add kernel/locking/lockdep.c:3328 [inline]
validate_chain kernel/locking/lockdep.c:3952 [inline]
__lock_acquire+0x1528/0x1f40 kernel/locking/lockdep.c:5288
lock_acquire kernel/locking/lockdep.c:5942 [inline]
lock_acquire+0x1d1/0x380 kernel/locking/lockdep.c:5899
down_read+0x94/0x4c0 kernel/locking/rwsem.c:1574
rds_trans_get_preferred+0xf7/0x2c0 net/rds/transport.c:100
__rds_conn_create+0xad5/0x2650 net/rds/connection.c:252
rds_conn_create+0x44/0x60 net/rds/connection.c:384
rds_ib_cm_handle_connect+0x62b/0x1220 net/rds/ib_cm.c:860
rds_rdma_cm_event_handler_cmn+0x59f/0x9b0 net/rds/rdma_transport.c:91
cma_listen_handler+0x11a/0x180 drivers/infiniband/core/cma.c:2716
cma_cm_event_handler+0x99/0x300 drivers/infiniband/core/cma.c:2181
cma_ib_req_handler+0x1be2/0x5700 drivers/infiniband/core/cma.c:2461
cm_process_work+0x46/0x440 drivers/infiniband/core/cm.c:1869
cm_queue_work_unlock+0x5d/0x250 drivers/infiniband/core/cm.c:933
cm_req_handler drivers/infiniband/core/cm.c:2235 [inline]
cm_work_handler+0x638d/0xc860 drivers/infiniband/core/cm.c:3849
process_one_work+0xac7/0x1b10 kernel/workqueue.c:3495
process_scheduled_works kernel/workqueue.c:3578 [inline]
worker_thread+0x5ef/0xe50 kernel/workqueue.c:3659
kthread+0x373/0x450 kernel/kthread.c:436
ret_from_fork+0x730/0xd60 arch/x86/kernel/process.c:158
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245
RDS/IB: Active conn connected <::ffff:172.20.20.170,::ffff:172.20.20.170,0> version 3.1
RDS/IB: Passive conn connected <::ffff:172.20.20.170,::ffff:172.20.20.170,0> version 3.1