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 09ECD369322 for ; Fri, 5 Sep 2025 17:22:03 +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=1757092924; cv=none; b=lolsw0Vwafv7YwJCTzLXRAnrdDx6s/hikPPypP2ZhXJgfQInjq2eE6nci/S88CnUaZwFkcoPXJenymGE6mU8ZcnBZ4DRBIKsZ3qlJGCMa5WOHBZOWtK6l65NhXy/2YpcbNlaJTy4YwhPd+JO/p9T6wjj1Qo+bBLKTJGjqh9QvPw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1757092924; c=relaxed/simple; bh=GZMy+tsvmUtgVOJlsyjgXD6pXKbHta9TIwfLTIkw7Ag=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=reb3mln1LalZ7iCCfmQcQ/ym0jadxsHI4+vU4csIZNaBWa/3AdMXMU8EDa9EPnBWW9XZzUoFYV8z2Y8eVM4gC44DB5ex/FLVyb2U7t90x5sQlH4t7AC1Bs1qbCzbLCvh1FuHTWKb4xTay7ofGDhWodOb5P7LC/7AZyEUM1hV8bw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=1WYefQ6U; 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="1WYefQ6U" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 36ADCC4CEF1; Fri, 5 Sep 2025 17:22:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1757092923; bh=GZMy+tsvmUtgVOJlsyjgXD6pXKbHta9TIwfLTIkw7Ag=; h=From:To:Cc:Subject:Date:Reply-to:From; b=1WYefQ6UlORWvBSYnwyQjvIAttxNkQyAPQA8jgEhf9A7ctJeVWTWmoIrX/6AHah+9 IMiK23u59nNwpN3yyqcwXdJk2LCGFHPil9fPXI1fRQ8rUFLOs9o8FcJLKt2u/FdHLj 3vFw9JpjxoG51hrWt+cchOGMSUOGJZjqwAYjA4kE= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-39681: x86/cpu/hygon: Add missing resctrl_cpu_detect() in bsp_init helper Date: Fri, 5 Sep 2025 19:20:55 +0200 Message-ID: <2025090545-CVE-2025-39681-ac80@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=3290; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=aORfNUh8+npzV6/Hm2VLXOkU31kAJZbf7vYeVibl9/Y=; b=owGbwMvMwCRo6H6F97bub03G02pJDBm7pd8eeVnur8m1qN77h0x/zJ6o9ACvxwE1U9iUgy2+T 1cI03/REcvCIMjEICumyPJlG8/R/RWHFL0MbU/DzGFlAhnCwMUpABM5Gc6woGvKpCkCLKFbCx31 T06PmG85Ta6OnWHBBHaVJ9NkagpvbjroIHiQKXf7jsBtAA== 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: x86/cpu/hygon: Add missing resctrl_cpu_detect() in bsp_init helper Since 923f3a2b48bd ("x86/resctrl: Query LLC monitoring properties once during boot") resctrl_cpu_detect() has been moved from common CPU initialization code to the vendor-specific BSP init helper, while Hygon didn't put that call in their code. This triggers a division by zero fault during early booting stage on our machines with X86_FEATURE_CQM* supported, where get_rdt_mon_resources() tries to calculate mon_l3_config with uninitialized boot_cpu_data.x86_cache_occ_scale. Add the missing resctrl_cpu_detect() in the Hygon BSP init helper. [ bp: Massage commit message. ] The Linux kernel CVE team has assigned CVE-2025-39681 to this issue. Affected and fixed versions =========================== Issue introduced in 5.8 with commit 923f3a2b48bdccb6a1d1f0dd48de03de7ad936d9 and fixed in 5.15.190 with commit 873f32201df8876bdb2563e3187e79149427cab4 Issue introduced in 5.8 with commit 923f3a2b48bdccb6a1d1f0dd48de03de7ad936d9 and fixed in 6.1.149 with commit fb81222c1559f89bfe3aa1010f6d112531d55353 Issue introduced in 5.8 with commit 923f3a2b48bdccb6a1d1f0dd48de03de7ad936d9 and fixed in 6.6.103 with commit 7207923d8453ebfb35667c1736169f2dd796772e Issue introduced in 5.8 with commit 923f3a2b48bdccb6a1d1f0dd48de03de7ad936d9 and fixed in 6.12.44 with commit a9e5924daa954c9f585c1ca00358afe71d6781c4 Issue introduced in 5.8 with commit 923f3a2b48bdccb6a1d1f0dd48de03de7ad936d9 and fixed in 6.16.4 with commit d23264c257a70dbe021b43b3bc2ee16134cd2c69 Issue introduced in 5.8 with commit 923f3a2b48bdccb6a1d1f0dd48de03de7ad936d9 and fixed in 6.17-rc3 with commit d8df126349dad855cdfedd6bbf315bad2e901c2f 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-2025-39681 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/x86/kernel/cpu/hygon.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/873f32201df8876bdb2563e3187e79149427cab4 https://git.kernel.org/stable/c/fb81222c1559f89bfe3aa1010f6d112531d55353 https://git.kernel.org/stable/c/7207923d8453ebfb35667c1736169f2dd796772e https://git.kernel.org/stable/c/a9e5924daa954c9f585c1ca00358afe71d6781c4 https://git.kernel.org/stable/c/d23264c257a70dbe021b43b3bc2ee16134cd2c69 https://git.kernel.org/stable/c/d8df126349dad855cdfedd6bbf315bad2e901c2f