From owner-svn-src-all@freebsd.org Sun Feb 26 13:25:58 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 13912CEDD2B; Sun, 26 Feb 2017 13:25:58 +0000 (UTC) (envelope-from nyan@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D4B076CB; Sun, 26 Feb 2017 13:25:57 +0000 (UTC) (envelope-from nyan@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v1QDPumq020147; Sun, 26 Feb 2017 13:25:56 GMT (envelope-from nyan@FreeBSD.org) Received: (from nyan@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v1QDPuOX020146; Sun, 26 Feb 2017 13:25:56 GMT (envelope-from nyan@FreeBSD.org) Message-Id: <201702261325.v1QDPuOX020146@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: nyan set sender to nyan@FreeBSD.org using -f From: Takahashi Yoshihiro Date: Sun, 26 Feb 2017 13:25:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r314301 - head/sys/x86/x86 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 26 Feb 2017 13:25:58 -0000 Author: nyan Date: Sun Feb 26 13:25:56 2017 New Revision: 314301 URL: https://svnweb.freebsd.org/changeset/base/314301 Log: Fix the acpi idle support on i386 which was broken by r312910. The ifdefs were '#if !defined(__i386__) || !defined(PC98)' previously, so cpu_idle_acpi was enabled both i386 and amd64 except PC98. I was obfuscated by '#if !defined(__i386__)' condition. Submitted by: bde Reported by: bde Modified: head/sys/x86/x86/cpu_machdep.c Modified: head/sys/x86/x86/cpu_machdep.c ============================================================================== --- head/sys/x86/x86/cpu_machdep.c Sun Feb 26 12:54:27 2017 (r314300) +++ head/sys/x86/x86/cpu_machdep.c Sun Feb 26 13:25:56 2017 (r314301) @@ -451,9 +451,7 @@ struct { { cpu_idle_spin, "spin" }, { cpu_idle_mwait, "mwait" }, { cpu_idle_hlt, "hlt" }, -#if !defined(__i386__) { cpu_idle_acpi, "acpi" }, -#endif { NULL, NULL } }; @@ -470,11 +468,9 @@ idle_sysctl_available(SYSCTL_HANDLER_ARG if (strstr(idle_tbl[i].id_name, "mwait") && (cpu_feature2 & CPUID2_MON) == 0) continue; -#if !defined(__i386__) if (strcmp(idle_tbl[i].id_name, "acpi") == 0 && cpu_idle_hook == NULL) continue; -#endif p += sprintf(p, "%s%s", p != avail ? ", " : "", idle_tbl[i].id_name); } @@ -509,11 +505,9 @@ idle_sysctl(SYSCTL_HANDLER_ARGS) if (strstr(idle_tbl[i].id_name, "mwait") && (cpu_feature2 & CPUID2_MON) == 0) continue; -#if !defined(__i386__) if (strcmp(idle_tbl[i].id_name, "acpi") == 0 && cpu_idle_hook == NULL) continue; -#endif if (strcmp(idle_tbl[i].id_name, buf)) continue; cpu_idle_fn = idle_tbl[i].id_fn;