From: hanjun.guo@linaro.org (Hanjun Guo)
To: linux-arm-kernel@lists.infradead.org
Subject: [RFC part1 PATCH 4/7] ARM64 / ACPI: Introduce the skeleton of _PDC related for ARM64
Date: Wed, 4 Dec 2013 00:36:48 +0800 [thread overview]
Message-ID: <1386088611-2801-5-git-send-email-hanjun.guo@linaro.org> (raw)
In-Reply-To: <1386088611-2801-1-git-send-email-hanjun.guo@linaro.org>
The _PDC (Processor Driver Capabilities) object provides OSPM a
mechanism to convey to the platform the capabilities supported
by OSPM for processor power management.
OSPM evaluates _PDC prior to evaluating any other processor
power management objects returning configuration information.
This patch introduces the skeleton of _PDC related file to make
ACPI core can be compiled on ARM64.
Signed-off-by: Al Stone <al.stone@linaro.org>
Signed-off-by: Graeme Gregory <graeme.gregory@linaro.org>
Signed-off-by: Hanjun Guo <hanjun.guo@linaro.org>
---
arch/arm64/include/asm/acpi.h | 32 ++++++++++++++++++++++++++++++++
arch/arm64/include/asm/processor.h | 11 +++++++++++
arch/arm64/kernel/process.c | 5 +++++
3 files changed, 48 insertions(+)
create mode 100644 arch/arm64/include/asm/acpi.h
diff --git a/arch/arm64/include/asm/acpi.h b/arch/arm64/include/asm/acpi.h
new file mode 100644
index 0000000..c186f5b
--- /dev/null
+++ b/arch/arm64/include/asm/acpi.h
@@ -0,0 +1,32 @@
+/*
+ * Copyright (C) 2013, Al Stone <al.stone@linaro.org>
+ *
+ * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ */
+
+#ifndef _ASM_ARM_ACPI_H
+#define _ASM_ARM_ACPI_H
+
+static inline bool arch_has_acpi_pdc(void)
+{
+ return false; /* always false for now */
+}
+
+static inline void arch_acpi_set_pdc_bits(u32 *buf)
+{
+ return;
+}
+
+#endif /*_ASM_ARM_ACPI_H*/
diff --git a/arch/arm64/include/asm/processor.h b/arch/arm64/include/asm/processor.h
index 45b20cd..73b1d3a 100644
--- a/arch/arm64/include/asm/processor.h
+++ b/arch/arm64/include/asm/processor.h
@@ -162,6 +162,17 @@ static inline void spin_lock_prefetch(const void *x)
#define HAVE_ARCH_PICK_MMAP_LAYOUT
+#ifdef CONFIG_ACPI
+/*
+ * FIXME: there is no MWAIT on ARM, should be WFI or something else,
+ * and modify drivers/acpi/processor_core.c too.
+ */
+enum idle_boot_override { IDLE_NO_OVERRIDE = 0, IDLE_HALT, IDLE_NOMWAIT,
+ IDLE_POLL, IDLE_FORCE_MWAIT };
+
+extern unsigned long boot_option_idle_override;
+#endif
+
#endif
#endif /* __ASM_PROCESSOR_H */
diff --git a/arch/arm64/kernel/process.c b/arch/arm64/kernel/process.c
index de17c89..2cd4182 100644
--- a/arch/arm64/kernel/process.c
+++ b/arch/arm64/kernel/process.c
@@ -347,3 +347,8 @@ unsigned long randomize_et_dyn(unsigned long base)
{
return randomize_base(base);
}
+
+#ifdef CONFIG_ACPI
+unsigned long boot_option_idle_override = IDLE_NO_OVERRIDE;
+EXPORT_SYMBOL(boot_option_idle_override);
+#endif
--
1.7.9.5
next prev parent reply other threads:[~2013-12-03 16:36 UTC|newest]
Thread overview: 68+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-03 16:36 [RFC part1 PATCH 0/7] Make ACPI core running on ARM64 Hanjun Guo
2013-12-03 16:36 ` [RFC part1 PATCH 1/7] ACPI: Make ACPI core running without PCI " Hanjun Guo
2013-12-03 16:41 ` Matthew Garrett
2013-12-04 14:08 ` Hanjun Guo
2013-12-05 22:04 ` Arnd Bergmann
2013-12-06 15:04 ` [Linaro-acpi] " Tomasz Nowicki
2013-12-06 17:23 ` Arnd Bergmann
2013-12-09 4:12 ` Hanjun Guo
2013-12-09 11:50 ` Catalin Marinas
2013-12-09 13:05 ` Hanjun Guo
2013-12-09 16:35 ` Arnd Bergmann
2013-12-09 16:55 ` Catalin Marinas
2013-12-09 17:20 ` Arnd Bergmann
2013-12-09 18:01 ` Catalin Marinas
2013-12-16 20:51 ` Graeme Gregory
2013-12-17 11:29 ` Catalin Marinas
2013-12-19 11:30 ` Graeme Gregory
2013-12-19 14:01 ` Arnd Bergmann
2013-12-19 15:43 ` Catalin Marinas
2013-12-20 19:55 ` Mark Brown
2013-12-10 2:53 ` Hanjun Guo
2013-12-09 17:06 ` Matthew Garrett
2013-12-10 1:52 ` Hanjun Guo
2013-12-10 3:28 ` Arnd Bergmann
2013-12-10 19:22 ` Mark Brown
2013-12-10 20:00 ` Arnd Bergmann
2013-12-10 20:23 ` Mark Brown
2013-12-11 3:07 ` Arnd Bergmann
2013-12-11 11:02 ` Mark Brown
2013-12-10 9:56 ` Linus Walleij
2013-12-09 23:34 ` Rob Herring
2013-12-03 16:47 ` One Thousand Gnomes
2013-12-04 14:15 ` Hanjun Guo
2013-12-03 16:36 ` [RFC part1 PATCH 2/7] ARM64 : Add dummy asm/cpu.h Hanjun Guo
2013-12-03 17:13 ` Mark Rutland
2013-12-04 15:00 ` Hanjun Guo
2013-12-03 17:59 ` Mark Brown
2013-12-03 16:36 ` [RFC part1 PATCH 3/7] ACPI / processor_core: Rework _PDC related stuff to make it more arch-independent Hanjun Guo
2013-12-03 16:46 ` Matthew Garrett
2013-12-04 14:11 ` Hanjun Guo
2013-12-03 16:51 ` One Thousand Gnomes
2013-12-03 17:02 ` Matthew Garrett
2013-12-04 14:16 ` Hanjun Guo
2013-12-03 16:36 ` Hanjun Guo [this message]
2013-12-03 16:53 ` [RFC part1 PATCH 4/7] ARM64 / ACPI: Introduce the skeleton of _PDC related for ARM64 One Thousand Gnomes
2013-12-04 14:17 ` Hanjun Guo
2013-12-03 17:12 ` Rob Herring
2013-12-04 14:30 ` Hanjun Guo
2013-12-03 16:36 ` [RFC part1 PATCH 5/7] ARM64 / ACPI: Introduce arm_core.c and its related head file Hanjun Guo
2013-12-03 18:03 ` Mark Rutland
2013-12-04 15:48 ` Hanjun Guo
2013-12-04 5:46 ` Zheng, Lv
2013-12-04 15:53 ` Hanjun Guo
2013-12-04 19:47 ` Al Stone
2013-12-05 3:38 ` Arnd Bergmann
2013-12-05 13:51 ` Hanjun Guo
2013-12-05 20:40 ` Arnd Bergmann
2013-12-05 14:09 ` Rob Herring
2013-12-05 14:27 ` Hanjun Guo
2013-12-03 16:36 ` [RFC part1 PATCH 6/7] ARM64 / ACPI: Introduce lowlevel suspend function Hanjun Guo
2013-12-03 16:36 ` [RFC part1 PATCH 7/7] ARM64 / ACPI: Enable ARM64 in Kconfig Hanjun Guo
2013-12-04 10:10 ` Graeme Gregory
2013-12-04 15:55 ` Hanjun Guo
2013-12-05 22:25 ` [RFC part1 PATCH 0/7] Make ACPI core running on ARM64 Arnd Bergmann
2013-12-06 13:58 ` Mark Brown
2013-12-08 2:44 ` Arnd Bergmann
2013-12-08 19:40 ` Mark Brown
2013-12-10 9:45 ` Linus Walleij
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1386088611-2801-5-git-send-email-hanjun.guo@linaro.org \
--to=hanjun.guo@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).