From patchwork Sat Feb 8 13:10:16 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hanjun Guo X-Patchwork-Id: 24345 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-oa0-f70.google.com (mail-oa0-f70.google.com [209.85.219.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 735A220967 for ; Sat, 8 Feb 2014 13:11:19 +0000 (UTC) Received: by mail-oa0-f70.google.com with SMTP id m1sf20221635oag.1 for ; Sat, 08 Feb 2014 05:11:18 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=o8LBdJevg8svTE8zO+p3NvFC4pqjWfXwoFJr9RNhQiE=; b=mgNglEFiPgbWRyPemLP6iNlZtVPtn+FPewSNysmRbqdH7m/krcRW7Tz8U0EicpKXMp DCiKcVD3jCZWQs4FavSqWcAKo3fe46IEAxAV5gKxHERWQReoLL/W4rs8Vsa07oMl0zHc bXtiFTah4T0BCkSMZ39v7Ig3MNpv/PY5UOjXpcqICBZtZ9kRr7rOHXl0q7R5tDMp7dE0 QSk2csY7VrH1RRXQMs6hdd92eCCvW5HCy/bNqqobKMMtIQlvq//Z1Z+tXBprbqZDJDDC uGJEY+mIvPLA1c5baKSSyK5++H/q6pEWUyLg5g/YSk6QAp1hJsBnx663FJShAilebQHd tVOA== X-Gm-Message-State: ALoCoQmN/WeJ1oKLWC933XHRqDX/pfAdcAJYki9bM2y4cnf2Mn2rciN1n6S4WzFiBX6VtkjKsKhZ X-Received: by 10.182.104.200 with SMTP id gg8mr8422336obb.45.1391865078296; Sat, 08 Feb 2014 05:11:18 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.97.196 with SMTP id m62ls1446339qge.11.gmail; Sat, 08 Feb 2014 05:11:18 -0800 (PST) X-Received: by 10.220.99.7 with SMTP id s7mr14728306vcn.19.1391865078221; Sat, 08 Feb 2014 05:11:18 -0800 (PST) Received: from mail-vb0-f48.google.com (mail-vb0-f48.google.com [209.85.212.48]) by mx.google.com with ESMTPS id n15si2473626vcy.102.2014.02.08.05.11.18 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 08 Feb 2014 05:11:18 -0800 (PST) Received-SPF: neutral (google.com: 209.85.212.48 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.212.48; Received: by mail-vb0-f48.google.com with SMTP id q16so3488619vbe.35 for ; Sat, 08 Feb 2014 05:11:18 -0800 (PST) X-Received: by 10.58.100.100 with SMTP id ex4mr15029552veb.2.1391865078140; Sat, 08 Feb 2014 05:11:18 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp32352vcz; Sat, 8 Feb 2014 05:11:02 -0800 (PST) X-Received: by 10.68.133.229 with SMTP id pf5mr26091487pbb.115.1391865062427; Sat, 08 Feb 2014 05:11:02 -0800 (PST) Received: from mail-pd0-f176.google.com (mail-pd0-f176.google.com [209.85.192.176]) by mx.google.com with ESMTPS id r7si8557271pbk.357.2014.02.08.05.11.02 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 08 Feb 2014 05:11:02 -0800 (PST) Received-SPF: neutral (google.com: 209.85.192.176 is neither permitted nor denied by best guess record for domain of hanjun.guo@linaro.org) client-ip=209.85.192.176; Received: by mail-pd0-f176.google.com with SMTP id w10so4250355pde.21 for ; Sat, 08 Feb 2014 05:11:02 -0800 (PST) X-Received: by 10.68.229.164 with SMTP id sr4mr25661463pbc.82.1391865062048; Sat, 08 Feb 2014 05:11:02 -0800 (PST) Received: from localhost ([39.182.20.40]) by mx.google.com with ESMTPSA id db3sm23571954pbb.10.2014.02.08.05.10.59 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Sat, 08 Feb 2014 05:11:01 -0800 (PST) From: Hanjun Guo To: "Rafael J. Wysocki" Cc: linux-acpi@vger.kernel.org, patches@linaro.org, linux-kernel@vger.kernel.org, linaro-acpi@lists.linaro.org, Hanjun Guo Subject: [PATCH v2 1/3] ACPI / idle: Make idle_boot_override depend on x86 and ia64 Date: Sat, 8 Feb 2014 21:10:16 +0800 Message-Id: <1391865018-3446-2-git-send-email-hanjun.guo@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1391865018-3446-1-git-send-email-hanjun.guo@linaro.org> References: <1391865018-3446-1-git-send-email-hanjun.guo@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: hanjun.guo@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.212.48 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , idle_boot_override depends on x86 and ia64 now, and we can not foresee it will be used on ARM or ARM64,so move the code into CONFIG_X86 and CONFIG_IA64 #ifdefs to make processor_core.c can be compiled on ARM64. Signed-off-by: Hanjun Guo --- drivers/acpi/processor_core.c | 40 ++++++++++++++++++++++------------------ 1 file changed, 22 insertions(+), 18 deletions(-) diff --git a/drivers/acpi/processor_core.c b/drivers/acpi/processor_core.c index 46583d7..01b2656 100644 --- a/drivers/acpi/processor_core.c +++ b/drivers/acpi/processor_core.c @@ -19,24 +19,6 @@ #define _COMPONENT ACPI_PROCESSOR_COMPONENT ACPI_MODULE_NAME("processor_core"); -static int __init set_no_mwait(const struct dmi_system_id *id) -{ - printk(KERN_NOTICE PREFIX "%s detected - " - "disabling mwait for CPU C-states\n", id->ident); - boot_option_idle_override = IDLE_NOMWAIT; - return 0; -} - -static struct dmi_system_id processor_idle_dmi_table[] __initdata = { - { - set_no_mwait, "Extensa 5220", { - DMI_MATCH(DMI_BIOS_VENDOR, "Phoenix Technologies LTD"), - DMI_MATCH(DMI_SYS_VENDOR, "Acer"), - DMI_MATCH(DMI_PRODUCT_VERSION, "0100"), - DMI_MATCH(DMI_BOARD_NAME, "Columbia") }, NULL}, - {}, -}; - static int map_lapic_id(struct acpi_subtable_header *entry, u32 acpi_id, int *apic_id) { @@ -379,13 +361,35 @@ early_init_pdc(acpi_handle handle, u32 lvl, void *context, void **rv) return AE_OK; } +#if defined(CONFIG_X86) || defined(CONFIG_IA64) +static int __init set_no_mwait(const struct dmi_system_id *id) +{ + printk(KERN_NOTICE PREFIX "%s detected - " + "disabling mwait for CPU C-states\n", id->ident); + boot_option_idle_override = IDLE_NOMWAIT; + return 0; +} + +static struct dmi_system_id processor_idle_dmi_table[] __initdata = { + { + set_no_mwait, "Extensa 5220", { + DMI_MATCH(DMI_BIOS_VENDOR, "Phoenix Technologies LTD"), + DMI_MATCH(DMI_SYS_VENDOR, "Acer"), + DMI_MATCH(DMI_PRODUCT_VERSION, "0100"), + DMI_MATCH(DMI_BOARD_NAME, "Columbia") }, NULL}, + {}, +}; +#endif + void __init acpi_early_processor_set_pdc(void) { +#if defined(CONFIG_X86) || defined(CONFIG_IA64) /* * Check whether the system is DMI table. If yes, OSPM * should not use mwait for CPU-states. */ dmi_check_system(processor_idle_dmi_table); +#endif acpi_walk_namespace(ACPI_TYPE_PROCESSOR, ACPI_ROOT_OBJECT, ACPI_UINT32_MAX,