From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=209.85.210.43 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796512218; b=R2Jd5+YIe8hukp0fRESxHRqyNag67KzTqOnTrAqjIvSBcfGq6JfegHoxRqAA9bFX7V4N 658f78tkqjLs8yGWcept0h3ipAM/5/4DBRkuxn8v++4asHEmP35A4g2q7apiNeyygE+B+ Eg/ij9FrdmsgR58RXYY16W/5kJokvZ+tRWS+mqtgGfqwuazO7hXq0r3v7mouPRcrMyWN4 c323X3wliejDSO6Xy59pOePtdvZtGaCOLEFKk85TxpmdbBMqaksfA+yoQHUAtM2bkrLdl rY0Dx9URLxNSgsnkTu3t27h6SMJm458F8FuPM4wU0cRZeoI59mYpSMNhzDIWi4npH9Q== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796512218; h=DMARC-Filter:Received:DKIM-Signature:X-Google-DKIM-Signature: X-Gm-Message-State:X-Gm-Gg:X-Received:Received:From:To:Cc:Subject: Date:Message-ID:X-Mailer:MIME-Version:Content-Transfer-Encoding; bh=dIArM64qXPY6PKS0uqHiVACwsVgP7N4mA6+/UGS2/U4=; b=pUzeARgTL3orx8cesvN7/IGQJuGGdr20qMxkIVRH3okeVTGnjE9WHjRqw7S7cgVyRh/v Ul9iazKN2S3DwwgEX1JVO28eV3kU42fX3CPFd4Lew/lejWzGh2/6kbLxkF6fIGGtcvU1P 7ZHxUP6HUun4CBd/u3rDnb6xNFydk3wT5pE5iK/PRwoWDGbIC0E5W8eynRJVkm6hYVeaA gC2Cpgt7BcJRhs3Lk+K9vKTSsdPH0u/4Pe4v7Yk1mlRBe4Ym8K1Jveux1ZCds7mSNKlfj YnutIa/xOPMQ0ZSfbB0JCVmcL1AfqC3ocZ8tX+N0pcwzFjt8GqCoDWfx+Bvkzq1l28g== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=kernel.dk; spf=pass smtp.mailfrom=kernel.dk; dkim=pass header.d=kernel.dk header.i=@kernel.dk header.a=rsa-sha256 header.s=google header.b=IoBQDARd; arc=none smtp.remote-ip=209.85.210.43 Received: from mail-ot1-f43.google.com (mail-ot1-f43.google.com [209.85.210.43]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DAEA6606A31F for ; Sat, 5 Dec 2026 23:10:16 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org DAEA6606A31F Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=kernel.dk Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=kernel.dk Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=kernel.dk header.i=@kernel.dk header.a=rsa-sha256 header.s=google header.b=IoBQDARd Received: by mail-ot1-f43.google.com with SMTP id 46e09a7af769-843b6f8e2c7so3243989a34.1 for ; Sat, 05 Dec 2026 15:10:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.dk; s=google; t=1796512216; x=1797117016; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to:content-type; bh=dIArM64qXPY6PKS0uqHiVACwsVgP7N4mA6+/UGS2/U4=; b=IoBQDARdz4cYknKRcP5cdMqedDf9fnxEH8VhF/rWim256Y4QMJmBNpKg0chu6TX3PP P0i0QC639RJnPj+GeEJyY30NesDpJjXfVkhw+8DhI3C8I7WPLcxBwRMpM0J4uOa9SVHv 97p50zZQO8zKwv4rNA08uX7n9lyS321cEgMz5wHpibUp5sou88t/WKYrLUiwNLTFGPk7 fotHzTwM2PVLVg+uzkGNByaAmfsHII0Fb9Hea1XCEDav/TU2N+YItDz4qe9znLc+gHSq GAyqBkXRgVOhbLGH24Is+chmt/YvkreTPMTys6odk/tWQJmUXvqSYwmSvmNGCzq7Y2Up 2NoA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796512216; x=1797117016; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to:content-type; bh=dIArM64qXPY6PKS0uqHiVACwsVgP7N4mA6+/UGS2/U4=; b=24lfQs8PAXc35aWoXCbrSTh4mQ1gJmfdoiuC8vDTjTRpTc3IfgMBzzuBH43P8wwIQl kYc46A3C9nxd5Tv/dGO1sRS9fCx4rgDTsLYiSfQnyx1O4ARqrf+CuWkGlI+BX4oI2Eda It1VvIfE2QZeepjJEvlkLdMFDQ0WMa/kB0gsuC1i8ZaqR42pjuSrkfTjRQBLERCVXGLI eftT/mCqF7GxfeeLGwAwcGCBinp+VeZyj75bmaI0IBfX7l1Q2b0wg3+1oWlZGt0vqTKE CxaUhH3tyYNKcqsCzDakrRza7B74OaoyY5BXiuHXPqb6D6chisJl3+t93Zss65fPLBjo 2oCw== X-Gm-Message-State: APuU4Z+r/ge6xPIKS9aQu9mE6pGzpP8NLu2Zf97+DwtzHb47WMy1D8Bq 30f6XjqHpegg+iJ363fLOQVcvzxDbGzaiAmx44RIW+rl1tRlL9wA9+W4dVziklbDklif79dvglS xYRRlq5s= X-Gm-Gg: AZFdTZfmi2QY3rNtCemodrj06p/iUV2BN8cr1dkysotAgxAhWG+oDsGK3/lGtMn4Wjl eQtxpkQCBGf0Sq82ETXu/UoJpnzhd5wBdRIWMuWwZLAlgb7QUj0Zb/HUiMfj7Jfe8kZ73ZOLby4 1LIS+jH/PjRD/9Qqn+j61grT3CG4IKX0J+QdmMOm6aMoS/sQDlhsTHcuUB5JeZQqUr6Mqf+FTfe P+7lYSonTN6psZKuiI9gRIkk4loHdfueR71PI+LOloQlX2ecnYaNt9q409rR2ua4s5quzP4auFu BXgNL1MtCF5LCSGvrPdJKjiHtR6lac+yNcEgJEH/FJfpU80gtTNmB/htXZSSoljd8WkXffpdfCD iYLH6bX9D31idUXX+efKhF8aNjixhE5otBAcUyXOv4pXgbtiglSR2Hx4sXVYyqjl9nitqak3ujQ 4nLXM9No28yeuvzauUMQuM5TnM8tWrRHsyO0B+lMkELUxuYArfTJYPvEPE3cPipBdbT6dValfDe 5noibhl2oWHylfJNk3K3k3nITHjX2NNtY2RNyce8fHTgOQ1B20iz7yGF+b/L2wbeLQiW4Sjw3ae glRY2tfRkLSrdJaa2z13k6Sn651J94NYx3fvh/mCTeMm3EAxXUbMOTmTMyYVq54otpbYRHRnPNt izBlVHuVwIQaazFpkCfKHfxk/hcRHrHM+4W2S X-Received: by 2002:a05:6830:230a:b0:81a:adf1:ae71 with SMTP id 46e09a7af769-863f89142e5mr7046319a34.4.1796512215732; Sat, 05 Dec 2026 15:10:15 -0800 (PST) Received: from r7625 ([96.43.243.2]) by smtp.gmail.com with ESMTPSA id 46e09a7af769-863f8313082sm6309624a34.16.2026.12.05.15.10.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 05 Dec 2026 15:10:14 -0800 (PST) From: Jens Axboe To: stable@vger.kernel.org Cc: io-uring@vger.kernel.org, gregkh@linuxfoundation.org Subject: [PATCH 6.1.y 0/9] io_uring fixes for 6.1-stable Date: Sat, 5 Dec 2026 23:10:03 +0000 Message-ID: <20261205231012.3977993-1-axboe@kernel.dk> X-Mailer: git-send-email 2.55.0 X-Mailing-List: io-uring@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Hi Greg, Here are 9 io_uring patches for 6.1-stable. Patches 1, 4, 5, 8 and 9 went to Linus in io_uring-7.4-20261127, merge commit 7cd8495c0f16 ("Merge tag 'io_uring-7.4-20261127' of git://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux"). Patches 2, 3, 6 and 7 are older mainline commits, backported because the fixes are written on top of them: 2 (v6.19) and 3 (v7.4-rc1, Fixes: 2) for 4, which needs ctx->tctx_lock; 6 (v6.13) and 7 (v6.13, Fixes: 6) for 8, which needs the raw timeout_lock. The series applies on top of v6.1.193 plus queue-6.1 at stable-queue commit 16dfa5cc8e2f. It also applies to v6.1.193 alone. Patches 2, 3, 6, 7, 8 and 9 needed changes for 6.1. The [axboe: ...] note at the end of each says what was changed and why. The rest are the upstream changes as they are. Please take these together, in this order: 2-4; 6-8. Testing: the liburing test suite (liburing-2.15-76-ged312b3c) was run in KVM guests with PROVE_LOCKING and PROVE_RAW_LOCK_NESTING on two kernels: v6.1.193, and v6.1.193 plus these patches and the io_uring patches already in queue-6.1. The patched kernel fails exactly the tests that v6.1.193 fails (napi-test times out; cancel-fd-userdata, io-wq-unused-exit, poll, poll-mshot-wake, send-zerocopy and timestamp fail), all from the test environment. No WARNING, BUG, lockdep or KASAN report in dmesg on either kernel. io_uring/ builds without warnings on v6.1.193 plus queue-6.1 plus this series. CVE assessment, by the io_uring maintainer: Should get a CVE: 4/9 io_uring: free the ring after a grace period 5/9 io_uring/filetable: don't install O_PATH files 8/9 io_uring/cancel: always walk links under timeout_lock 9/9 io_uring/net: restore the cmsg buffer on recvmsg retry Should not get a CVE: 1/9 io_uring/net: don't copy msg_name on a recvmsg retry Writes past msg_name, in the caller's own user memory only. 2/9 io_uring/tctx: add separate lock for list of tctx's in ctx prep for 4/9 3/9 io_uring: free the task context after a grace period Fixes 2/9 of this series, no release has the bug. 6/9 io_uring: make ctx->timeout_lock a raw spinlock prep for 8/9 7/9 io_uring/timeout: flush timeouts outside of the timeout lock Fixes 6/9 of this series, no release has the bug. Chris Mason (6): io_uring/net: don't copy msg_name on a recvmsg retry io_uring: free the task context after a grace period io_uring: free the ring after a grace period io_uring/filetable: don't install O_PATH files io_uring/cancel: always walk links under timeout_lock io_uring/net: restore the cmsg buffer on recvmsg retry Jens Axboe (3): io_uring/tctx: add separate lock for list of tctx's in ctx io_uring: make ctx->timeout_lock a raw spinlock io_uring/timeout: flush timeouts outside of the timeout lock include/linux/io_uring_types.h | 15 +++++- io_uring/cancel.c | 3 ++ io_uring/filetable.c | 3 ++ io_uring/io_uring.c | 37 +++++++++------ io_uring/net.c | 12 +++++ io_uring/tctx.c | 13 ++++-- io_uring/timeout.c | 83 ++++++++++++++++++++-------------- 7 files changed, 112 insertions(+), 54 deletions(-) -- 2.55.0