From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1795897931; b=ENhtz9+E+iZzntIjbaYQgnbAfeX5vVhEfSfgn/wRIFT5ubQNyNA6E6eLbOuwf66mbOkt JhIJTvnbE7pltoaIAkhCdCfx7iF0Hk5onoY3zniKTP6+MOn0G5gNFCcYq+IeV3njxtZv8 b7LZ0uOb+B7EkcvNyiTpo8QK6CSwXceRwyrTYLtOKs9GDudL2e+ThYh9GwNlOB1J0jU9S UXF6Vs8mILRTStY72YeAYrgNKqUVjaIDQsDJhz9zeQL8nGYCZH/h7+jThcthepgAWAesd vFffE+rJ0QxYxx/8zAIaCcKPZ1DNe6CefxjDakO0sLg/RtzI8Mh0AK2bZWlM8HqBx5w== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795897931; h=Received:DKIM-Signature:Message-ID:From:Subject:Reply-To:To:Cc: In-Reply-To:References:Content-Type:Content-Transfer-Encoding:Date; bh=3PitTHdaobeZ73MdVIN0Ilak6qaeFmo2FPHR33rH5EU=; b=PRD1/H9N5CzNfrZXM8ih24KxqED6P+8JZkRUEIVyqbzLB9oSs2w7Iquc7jbfIqSRnRtm svfDCyTe6QYPFcSm0nLqCnbGakShkja3WzVZVcovX7ryfvmdDouyW9c2X5uwjh/aVMPWN gPIe1luE/42KvhxOOB0CCczmmKYVxWg9KjnHDRKxNuE4JMoX5laVzPyYwtcid6IEp53Jx 1D8PcPcZRIPOfwhCh+ReI3JIptwaPtIluTphtvYDEziisDHVFB/iCVqyEDi31aIlFyjUx r5cMCdZBgUxt1DPrWIGDU0UfQqe3kVMfrSu5dT4leo1pFaPsn2mLXV8TqpVCo6683kg== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=bthWxrdd; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B6CFA606A31C for ; Sat, 28 Nov 2026 20:32:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=bthWxrdd Received: by smtp.kernel.org (Postfix) with ESMTPSA id 459081F000C1; Sat, 28 Nov 2026 20:32:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1795897931; bh=3PitTHdaobeZ73MdVIN0Ilak6qaeFmo2FPHR33rH5EU=; h=From:Subject:Reply-To:To:Cc:In-Reply-To:References:Date; b=bthWxrdd4nv7CFm03+QunQ6BP/RBj+GDoI3ybMaXCNmuI+ZNvXhq9hTkhZTwtj1bW dp356Pc2PstERnRGbgNqGQnA1/gUSf8XIlTAXydCQezS8YBh/DcrNPVExVu4UFv74I ARXtcCT7Cj19b7SBaWhzvKGUPmiIeBwT0iH1tDjCvepo91N31CIUwhLZx/52+pXg3d 3+AefBKPrVTEQtpa9xD60PZsu2Ww7avcorZDXP2Y7PoMxnC19NMwcrlZAlKSF6vc0O QeEo5OUcHPwTkB5bXrH2yEYlxXFBbNXF+ydsxQDkajuiwmmFf9v3vttfq9nSVeoZ3h jEIGsJHHFEbBg== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH v2 rdma-rc] RDMA/siw: Fix NULL dereference when disconnect races the RTR callback Reply-To: sashiko-reviews@lists.linux.dev To: "Andrew Stellman" Cc: linux-rdma@vger.kernel.org In-Reply-To: <20261128202452.45307-1-bugs@stellman-greene.com> References: <20261128140843.59029-1-bugs@stellman-greene.com> <20261128202452.45307-1-bugs@stellman-greene.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Sat, 28 Nov 2026 20:32:10 +0000 X-Mailing-List: linux-rdma@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list > From: Andrew Stellman >=20 > siw_rtr_data_ready() releases sk_callback_lock and then calls > siw_qp_socket_assoc(), which reads cep->sock->sk before it takes the > write lock. A concurrent disconnect can disassociate the socket and > clear cep->sock in that gap. >=20 > In QEMU (arm64) on mainline as of 2026-11-28 with KASAN, a test server > accepted an MPA v2 connection that waits for the peer's RTR frame. The > server calls rdma_disconnect() when it gets the ESTABLISHED event. The > peer sent an incomplete RTR header. With a test-only one second delay > added after the callback unlock, this oopsed: >=20 > Unable to handle kernel paging request at virtual address dfff800000000= 003 > KASAN: null-ptr-deref in range [0x0000000000000018-0x000000000000001f] > [ ... ] > The fix and this changelog were drafted with OpenAI GPT-6 (Codex) and > Claude Opus 5.5, and both were reviewed by me. >=20 > Fixes: 6c52fdc244b5 ("rdma/siw: connection management") > Signed-off-by: Andrew Stellman Sashiko has reviewed this patch and found no issues. --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/20261128202452.4530= 7-1-bugs@stellman-greene.com?part=3D1