From: Ingo Molnar <mingo@kernel.org>
To: "Li, Aubrey" <aubrey.li@linux.intel.com>
Cc: Ingo Molnar <mingo@redhat.com>,
"alan@linux.intel.com" <alan@linux.intel.com>,
Arjan van de Ven <arjan@linux.intel.com>,
"Rafael J. Wysocki" <rjw@rjwysocki.net>,
"Brown, Len" <len.brown@intel.com>,
"H. Peter Anvin" <hpa@linux.intel.com>,
x86@kernel.org, LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2] x86: Bypass legacy PIC and PIT in ACPI hardware reduced mode
Date: Wed, 11 Mar 2015 07:23:24 +0100 [thread overview]
Message-ID: <20150311062324.GA29788@gmail.com> (raw)
In-Reply-To: <54FFC593.6070002@linux.intel.com>
* Li, Aubrey <aubrey.li@linux.intel.com> wrote:
> On a platform in ACPI Hardware-reduced mode, the legacy PIC and PIT
> may not be initialized even though they may be present in silicon.
> Touching these legacy components causes unexpected result on system.
s/causes unexpected result on system/
causes unexpected results on the system
>
> On Bay Trail-T(ASUS-T100) platform, touching these legacy components
s/On Bay Trail-T(ASUS-T100) platform/
On the Bay Trail-T(ASUS-T100) platform
> blocks platform hardware low idle power state(S0ix) during system
> suspend. So we should bypass them in ACPI hardware reduced mode.
>
> Suggested-by: Arjan van de Ven <arjan@linux.intel.com>
> Signed-off-by: Li Aubrey <aubrey.li@linux.intel.com>
> Cc: Len Brown <len.brown@intel.com>
> Cc: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> Cc: Alan Cox <alan@linux.intel.com>
> ---
> arch/x86/kernel/acpi/boot.c | 21 +++++++++++++++++++++
> 1 file changed, 21 insertions(+)
>
> diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c
> index b9e30da..1e5a7865 100644
> --- a/arch/x86/kernel/acpi/boot.c
> +++ b/arch/x86/kernel/acpi/boot.c
> @@ -1343,6 +1343,24 @@ static int __init dmi_ignore_irq0_timer_override(const struct dmi_system_id *d)
> }
>
> /*
> + * ACPI offers an alternative platform interface model that removes
> + * ACPI hardware requirements for platforms that do not implement
> + * the PC Architecture.
> + *
> + * We initialize the Hardware-reduced ACPI model here
> + */
> +static void __init acpi_reduced_hw_init(void)
> +{
> + /*
> + * Override x86_init functions and bypass legacy pic
> + * in Hardware-reduced ACPI mode
> + */
> + x86_init.timers.timer_init = x86_init_noop;
> + x86_init.irqs.pre_vector_init = x86_init_noop;
> + legacy_pic = &null_legacy_pic;
> +}
> +
> +/*
> * If your system is blacklisted here, but you find that acpi=force
> * works for you, please contact linux-acpi@vger.kernel.org
> */
> @@ -1541,6 +1559,9 @@ int __init early_acpi_boot_init(void)
> */
> early_acpi_process_madt();
>
> + if (acpi_gbl_reduced_hardware)
> + acpi_reduced_hw_init();
Ok, my final bike shed painting job would be to move the
'acpi_gbl_reduced_hardware' flag check inside acpi_reduced_hw_init():
that makes it nicely self-sustained and all in a single place.
With that fixed it looks good to me.
Should I merge it for v4.0 upstream merge, in tip:x86/urgent?
The 'touches hardware in unexpected ways' aspect qualifies it for
urgent treatment IMO.
Thanks,
Ingo
next prev parent reply other threads:[~2015-03-11 6:23 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-11 4:33 Li, Aubrey
2015-03-11 6:23 ` Ingo Molnar [this message]
2015-03-11 7:51 ` Li, Aubrey
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=20150311062324.GA29788@gmail.com \
--to=mingo@kernel.org \
--cc=alan@linux.intel.com \
--cc=arjan@linux.intel.com \
--cc=aubrey.li@linux.intel.com \
--cc=hpa@linux.intel.com \
--cc=len.brown@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=rjw@rjwysocki.net \
--cc=x86@kernel.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
Powered by JetHome