transport_{h2g,g2h,dgram,local} may become NULL on vsock_core_unregister(). Make sure a poorly timed `rmmod transport` won't lead to a NULL/stale pointer dereference.
Note that these oopses are pretty unlikely to happen in the wild. Splats were collected after sprinkling kernel with mdelay()s. Signed-off-by: Michal Luczaj <m...@rbox.co> --- Michal Luczaj (3): vsock: Fix transport_{h2g,g2h} TOCTOU vsock: Fix transport_g2h TOCTOU vsock: Fix transport_* TOCTOU net/vmw_vsock/af_vsock.c | 34 +++++++++++++++++++++++++++------- 1 file changed, 27 insertions(+), 7 deletions(-) --- base-commit: d0fa59897e049e84432600e86df82aab3dce7aa5 change-id: 20250523-vsock-transports-toctou-4b75d9c2a805 Best regards, -- Michal Luczaj <m...@rbox.co>