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 0014521ADC9 for ; Wed, 26 Feb 2025 02:27:32 +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=1740536853; cv=none; b=ftCOcVzkc0eHVu8UmQbR2yMIGzHbKjynjBdXxQpr+Wc+BsPzmTIzjD5vZRHoApDsammaeT1Lz3cpz/mFFA3UybIov4AA0dPDEGCo0PsfNDKG0XDfSIUlOmO42JsQgbZKWrjmjo2RzPjOymV6tguO5thWNMRIGTIoeT9ZhWQ+hPs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740536853; c=relaxed/simple; bh=bCU9P1NQD8uz+GQxel6d7cIQQVltnkcnbEKjCuNJWIQ=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=OKO++08b2NKsxcEaVgjdQ4DawJipszqXY4NQhn8yu2dozyICnUSIMiWR7H0k9p/8cR8WlyY+ZNRudlg+J7YVHU8Z8SKXt7B8gECxcVljuyi13CpydiTwMNBT3+4O8CqGdphdvOwReUAD9t1Wz+IzSebJcIHOVhAg7bvU9CgluFM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=jg5BtkfY; 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="jg5BtkfY" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C825FC4CEDD; Wed, 26 Feb 2025 02:27:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1740536852; bh=bCU9P1NQD8uz+GQxel6d7cIQQVltnkcnbEKjCuNJWIQ=; h=From:To:Cc:Subject:Date:Reply-to:From; b=jg5BtkfYpHd/wvwfCkYJ130dPRX9n7v1hJJ3pyBz4rKwovn752Hwn+HcxVzJ1a0ZE 1ZZZs8vaJ+6Rcp0u/+iJypd56nL2KxN9WlKdVDI7cJgDfDjS9jEWtPg5qB44j41bEa RXmw6RD+JAc907zIwfMrr0b4X3nvlmmto6LsikYw= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-49694: block: disable the elevator int del_gendisk Date: Wed, 26 Feb 2025 03:24:17 +0100 Message-ID: <2025022628-CVE-2022-49694-d7d9@gregkh> X-Mailer: git-send-email 2.48.1 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=2276; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=bCU9P1NQD8uz+GQxel6d7cIQQVltnkcnbEKjCuNJWIQ=; b=owGbwMvMwCRo6H6F97bub03G02pJDOn7qp7M4trwujxR7fbXP4lsO40VKhK3/L9tHrzJ++BHx fN/mBPvdMSyMAgyMciKKbJ82cZzdH/FIUUvQ9vTMHNYmUCGMHBxCsBE1j9gWHBDIJxj8dZdm5mL OTl0g9g2C50wO8ww32HrR46IRrtbZm3TLTiaIrvn5B9zAAA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit Description =========== In the Linux kernel, the following vulnerability has been resolved: block: disable the elevator int del_gendisk The elevator is only used for file system requests, which are stopped in del_gendisk. Move disabling the elevator and freeing the scheduler tags to the end of del_gendisk instead of doing that work in disk_release and blk_cleanup_queue to avoid a use after free on q->tag_set from disk_release as the tag_set might not be alive at that point. Move the blk_qos_exit call as well, as it just depends on the elevator exit and would be the only reason to keep the not exactly cheap queue freeze in disk_release. The Linux kernel CVE team has assigned CVE-2022-49694 to this issue. Affected and fixed versions =========================== Issue introduced in 5.16 with commit e155b0c238b20f0a866f4334d292656665836c8a and fixed in 5.18.8 with commit f28699fafc047ec33299da01e928c3a0073c5cc6 Issue introduced in 5.16 with commit e155b0c238b20f0a866f4334d292656665836c8a and fixed in 5.19 with commit 50e34d78815e474d410f342fbe783b18192ca518 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-49694 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: block/blk-core.c block/genhd.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/f28699fafc047ec33299da01e928c3a0073c5cc6 https://git.kernel.org/stable/c/50e34d78815e474d410f342fbe783b18192ca518