Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D60A3198E6F for ; Thu, 1 May 2025 14:19:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746109185; cv=none; b=LOgq9PIPDZaq7XdHJlXO4x+tHd0I6jFe4gvg5NN54VCzu/aLJ7gdb2tiQPxgcr9sXjKfnpGJRt8EovY6mugialInmy20FEC6y/H/XQpBsvEBRkz5kgg6uM8vLOoHYtM98qhY943fbaARkwtI50ifbbEteEZeSmQ5XHinc7pX8ao= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746109185; c=relaxed/simple; bh=piGFM+1gUp+McyZgKFyRA2RrtbOfkXs1/dNgn1QLtDg=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=fYky4QmRRK2KvUwgPE1DY14YLxIYOYUdhbwVv96DhDcYyPtbkgO4p+bW6XJKd80BBQbbTRJSe9XFuLsD2qmrbDLY8cefVMHw5/YjvFkcEUXM0OwcM9VjzavDrL1YxuF18JpaxkrIIJQOe5YTSfmX66iUP5prcCglg9/H1kEVDMY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=aPl5yhrD; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="aPl5yhrD" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4EC54C4CEE3; Thu, 1 May 2025 14:19:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1746109185; bh=piGFM+1gUp+McyZgKFyRA2RrtbOfkXs1/dNgn1QLtDg=; h=From:To:Cc:Subject:Date:Reply-to:From; b=aPl5yhrDcVFW5rRcI/+QTWdcYAwucOJcBoitbmNKLrPEqkd1M51A2slwt6Fq5dMfH ZjzDeRepmORdLtlzxG1D6jTkLslq2hPQFoQBq6ll+AEPAV9ePkGGrt7dOcC+093Nae DdZsgqtmADB1PtoE9dCV2Nprs99VOeBAPb03S08k= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-49929: RDMA/rxe: Fix mr leak in RESPST_ERR_RNR Date: Thu, 1 May 2025 16:11:59 +0200 Message-ID: <2025050111-CVE-2022-49929-d572@gregkh> X-Mailer: git-send-email 2.49.0 Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Reply-to: , X-Developer-Signature: v=1; a=openpgp-sha256; l=2635; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=KKMVLG8BEqKsVOrwXot+pVzugD41JpzfM1+GHRzdoOY=; b=owGbwMvMwCRo6H6F97bub03G02pJDBnCDYelYtT+ls//Ix33/VaBSzsz78+OnrnhLLEMcbPYm T+defKwI5aFQZCJQVZMkeXLNp6j+ysOKXoZ2p6GmcPKBDKEgYtTACYiqswwv9jnscFK+52dc85l 8Kvc3cX+uk9iL8NcmZ7yM7xVB4xaknnOv65+XNFt+/0+AA== X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: RDMA/rxe: Fix mr leak in RESPST_ERR_RNR rxe_recheck_mr() will increase mr's ref_cnt, so we should call rxe_put(mr) to drop mr's ref_cnt in RESPST_ERR_RNR to avoid below warning: WARNING: CPU: 0 PID: 4156 at drivers/infiniband/sw/rxe/rxe_pool.c:259 __rxe_cleanup+0x1df/0x240 [rdma_rxe] ... Call Trace: rxe_dereg_mr+0x4c/0x60 [rdma_rxe] ib_dereg_mr_user+0xa8/0x200 [ib_core] ib_mr_pool_destroy+0x77/0xb0 [ib_core] nvme_rdma_destroy_queue_ib+0x89/0x240 [nvme_rdma] nvme_rdma_free_queue+0x40/0x50 [nvme_rdma] nvme_rdma_teardown_io_queues.part.0+0xc3/0x120 [nvme_rdma] nvme_rdma_error_recovery_work+0x4d/0xf0 [nvme_rdma] process_one_work+0x582/0xa40 ? pwq_dec_nr_in_flight+0x100/0x100 ? rwlock_bug.part.0+0x60/0x60 worker_thread+0x2a9/0x700 ? process_one_work+0xa40/0xa40 kthread+0x168/0x1a0 ? kthread_complete_and_exit+0x20/0x20 ret_from_fork+0x22/0x30 The Linux kernel CVE team has assigned CVE-2022-49929 to this issue. Affected and fixed versions =========================== Issue introduced in 5.18 with commit 8a1a0be894da0d06bfbb496cc2dc3057fa83e103 and fixed in 6.0.8 with commit 50b35ad2864a9d66f802f9ce193d99bbef64e219 Issue introduced in 5.18 with commit 8a1a0be894da0d06bfbb496cc2dc3057fa83e103 and fixed in 6.1 with commit b5f9a01fae42684648c2ee3cd9985f80c67ab9f7 Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2022-49929 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: drivers/infiniband/sw/rxe/rxe_resp.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/50b35ad2864a9d66f802f9ce193d99bbef64e219 https://git.kernel.org/stable/c/b5f9a01fae42684648c2ee3cd9985f80c67ab9f7