Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 19 Jul 2026 14:04:27 +0000
From:      ShengYi Hung <aokblast@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: 02c440e20404 - main - hwpstate_intel: Minimize ifdef for i386 build
Message-ID:  <6a5cd96b.3e8dc.61ae8c13@gitrepo.freebsd.org>

index | next in thread | raw e-mail

The branch main has been updated by aokblast:

URL: https://cgit.FreeBSD.org/src/commit/?id=02c440e204041e92da403a64b70c2e1fdf3a4f73

commit 02c440e204041e92da403a64b70c2e1fdf3a4f73
Author:     ShengYi Hung <aokblast@FreeBSD.org>
AuthorDate: 2026-07-19 14:00:27 +0000
Commit:     ShengYi Hung <aokblast@FreeBSD.org>
CommitDate: 2026-07-19 14:03:48 +0000

    hwpstate_intel: Minimize ifdef for i386 build
    
    Reported by:    jrtc27
    Fixes:  bdc0f7678257
    MFC after:      3 days
    Sponsored by:   The FreeBSD Foundation
---
 sys/x86/cpufreq/hwpstate_intel.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/sys/x86/cpufreq/hwpstate_intel.c b/sys/x86/cpufreq/hwpstate_intel.c
index 56a33fa88e66..4cb80e4b2d44 100644
--- a/sys/x86/cpufreq/hwpstate_intel.c
+++ b/sys/x86/cpufreq/hwpstate_intel.c
@@ -362,9 +362,7 @@ intel_hwpstate_hybrid_cb(void *ctx)
 void
 intel_hwpstate_identify(driver_t *driver, device_t parent)
 {
-#ifndef __i386__
 	uint32_t small_cores = 0;
-#endif
 
 	if (device_find_child(parent, "hwpstate_intel", DEVICE_UNIT_ANY) != NULL)
 		return;
@@ -385,7 +383,6 @@ intel_hwpstate_identify(driver_t *driver, device_t parent)
 	if ((cpu_power_eax & CPUTPM1_HWP) == 0)
 		return;
 
-#ifndef __i386__
 	/*
 	 * On hybrid-core systems, package-level control cannot be used.
 	 * It may cause all cores to run at the E-core frequency because
@@ -396,7 +393,6 @@ intel_hwpstate_identify(driver_t *driver, device_t parent)
 	    intel_hwpstate_hybrid_cb, smp_no_rendezvous_barrier, &small_cores);
 	if (small_cores > 0 && small_cores < mp_ncores)
 		hwpstate_pkg_ctrl_enable = false;
-#endif
 
 	if (BUS_ADD_CHILD(parent, 10, "hwpstate_intel", device_get_unit(parent))
 	    == NULL)


home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?6a5cd96b.3e8dc.61ae8c13>