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 571A63161AB for ; Wed, 17 Sep 2025 14:57:48 +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=1758121068; cv=none; b=pUZZF5D4/e1CLjGOhns3Yxq+jWxz9QTscN+aVTPGNuGRx6UptWRd/u/mnNQ+qSDu/t72l7SdoCxPvsuLivINxqujD7x2+GIdSMPRj1+3J7y3cZ/xbVPuEjuVzxO+bcNeZjzItrBOv9OBra61PSVjIxw8AzSJMBc8hCZ7x6s2xlA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1758121068; c=relaxed/simple; bh=GT2nyzmdOQ7uMKndY2SUXbqqiyuDeDyIviOtsl6qsig=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=EG6wsc7NL3X5+WgJ58WWvn5S2tGgz/Aapb+L0Wp9LPsK9GAvQvwfbmB/wuEd3U1T/cHL9ndnD7ryvhOinz/UNKUVUBKi65JW4OVNavK4IbeGekcXUKUHovh8CLSLGthfCik3g6STkwn9/QO28as0z/U1iPEU5qzOhDtVarg91tI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=MDoJRAIh; 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="MDoJRAIh" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C0CBCC4CEE7; Wed, 17 Sep 2025 14:57:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1758121068; bh=GT2nyzmdOQ7uMKndY2SUXbqqiyuDeDyIviOtsl6qsig=; h=From:To:Cc:Subject:Date:Reply-to:From; b=MDoJRAIhlZKsWKLO7AAWnVERkdZCob4nJtTnOfEGZxaRX1d5gxf/DEbvrytRLoVNg CZYajpnL7rw1BLd2ruwmAyVi6fBf9CUARKFU+gbeu/XFBfGzSHBH1hCaw3+H4pDkRJ KF20Qgr8DIaU3LhBMcmgEBEW4vrgJRgbD5HhoKqI= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2023-53341: of/fdt: run soc memory setup when early_init_dt_scan_memory fails Date: Wed, 17 Sep 2025 16:56:40 +0200 Message-ID: <2025091718-CVE-2023-53341-896e@gregkh> X-Mailer: git-send-email 2.51.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=2836; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=I18IxSv/+F2GHdYM2IIGbtr1AJaCVhgrpXxkIud1VzM=; b=owGbwMvMwCRo6H6F97bub03G02pJDBmnzggdCC5yd1x1Qy1hTmnwXpXj/n+eX3pWMekNy77sm FALnUsbOmJZGASZGGTFFFm+bOM5ur/ikKKXoe1pmDmsTCBDGLg4BWAiP4sZFlyeNS2hxGXKuju7 mHtMDtd61ey8lMCwoGOeiavBB65fWm4CfzaJ+J8OU5J8DAA= 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: of/fdt: run soc memory setup when early_init_dt_scan_memory fails If memory has been found early_init_dt_scan_memory now returns 1. If it hasn't found any memory it will return 0, allowing other memory setup mechanisms to carry on. Previously early_init_dt_scan_memory always returned 0 without distinguishing between any kind of memory setup being done or not. Any code path after the early_init_dt_scan memory call in the ramips plat_mem_setup code wouldn't be executed anymore. Making early_init_dt_scan_memory the only way to initialize the memory. Some boards, including my mt7621 based Cudy X6 board, depend on memory initialization being done via the soc_info.mem_detect function pointer. Those wouldn't be able to obtain memory and panic the kernel during early bootup with the message "early_init_dt_alloc_memory_arch: Failed to allocate 12416 bytes align=0x40". The Linux kernel CVE team has assigned CVE-2023-53341 to this issue. Affected and fixed versions =========================== Issue introduced in 5.17 with commit 1f012283e9360fb4007308f04cfaeb205e34b684 and fixed in 6.0.19 with commit 04836fc5b720dfa32ff781383d84f63019abf9b9 Issue introduced in 5.17 with commit 1f012283e9360fb4007308f04cfaeb205e34b684 and fixed in 6.1.5 with commit c4849f18185fd4e93b04cd45552f8d68c0240e21 Issue introduced in 5.17 with commit 1f012283e9360fb4007308f04cfaeb205e34b684 and fixed in 6.2 with commit 2a12187d5853d9fd5102278cecef7dac7c8ce7ea 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-2023-53341 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: arch/mips/ralink/of.c drivers/of/fdt.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/04836fc5b720dfa32ff781383d84f63019abf9b9 https://git.kernel.org/stable/c/c4849f18185fd4e93b04cd45552f8d68c0240e21 https://git.kernel.org/stable/c/2a12187d5853d9fd5102278cecef7dac7c8ce7ea