CONTAP-732488: Soft lockup in ib_cm threads due to cm.state_lock held during synchronous RDMA Address Handle creation
Issue
A FAS2820 node (NetappUM-03) running ONTAP 9.16.1P12 experienced a system panic due to a CPU thread hang. The panic was triggered when the node watchdog detected that the ib_cm_2 thread on CPU 1 had been spinning for over 4001 milliseconds without yielding. Analysis shows this was caused by contention on a global InfiniBand Connection Manager (IB CM) state lock (cm.state_lock) in the iRDMA driver. The thread ib_cm_7 held this lock while busy-waiting inside the irdma_create_ah_wait function, waiting for hardware to confirm Address Handle (AH) creation. Due to repeated HA interconnect (NVRAM mirror) disconnect/reconnect cycles, multiple ib_cm_* threads attempted reconnections, causing excessive lock contention and ultimately leading to a watchdog-triggered panic. The root cause is a design issue in the iRDMA driver, where a potentially long-running hardware poll is performed while holding a global lock, stalling the entire IB CM subsystem.
