xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: "Luis R. Rodriguez" <mcgrof@kernel.org>
To: David Vrabel <david.vrabel@citrix.com>
Cc: "Luis R. Rodriguez" <mcgrof@kernel.org>,
	bp@alien8.de, hpa@zytor.com, tglx@linutronix.de,
	mingo@redhat.com, rusty@rustcorp.com.au,
	xen-devel@lists.xensource.com, matt@codeblueprint.co.uk,
	andrew.cooper3@citrix.com, x86@kernel.org,
	linux-kernel@vger.kernel.org, luto@amacapital.net, jlee@suse.com,
	lguest@lists.ozlabs.org, glin@suse.com,
	boris.ostrovsky@oracle.com, andriy.shevchenko@linux.intel.com,
	Josh Triplett <josh@joshtriplett.org>,
	robert.moore@intel.com, lv.zheng@intel.com,
	rafael.j.wysocki@intel.com, toshi.kani@hp.com,
	linux-acpi@vger.kernel.org, tiwai@suse.de
Subject: Re: [Xen-devel] [PATCH v4 11/14] pnpbios: replace paravirt_enabled() check with legacy device check
Date: Thu, 7 Apr 2016 23:42:16 +0200	[thread overview]
Message-ID: <20160407214216.GH1990@wotan.suse.de> (raw)
In-Reply-To: <57062C63.2010609@citrix.com>

On Thu, Apr 07, 2016 at 10:46:11AM +0100, David Vrabel wrote:
> On 07/04/16 01:06, Luis R. Rodriguez wrote:
> > Since we are removing paravirt_enabled() replace it with a
> > logical equivalent. Even though PNPBIOS is x86 specific we
> > add an arch-specific type call, which can be implemented by
> > any architecture to show how other legacy attribute devices
> > can later be also checked for with other ACPI legacy attribute
> > flags.
> > 
> > This implicates the first ACPI 5.2.9.3 IA-PC Boot Architecture
> > ACPI_FADT_LEGACY_DEVICES flag device, and shows how to add more.
> [...]
> > +struct x86_legacy_devices {
> > +	int pnpbios;
> > +};
> 
> It's not clear why pnpbios needs a new structure

I'm glad you asked. Dealing with placing pnpbios quirk in a more useful generic
fashion was perhaps the most difficult challenge in this series.  As I reviewed
possibilities to remove paravirt_enabled() the best prospect I found was to see
if Xen could instead use ACPI 5.2.9.3 IA-PC Boot Architecture flags to annotate
some quirks. It turns out that it is possible, but there are only so many flags,
and also, we didn't want to have a solution that incurred respective upstream
Xen hypervisor change, that would be silly.

To make this quirk more useful then this folds the pnpbios quirk as a sub
quirk under the more borad ACPI_FADT_LEGACY_DEVICES ACPI flag. What this
does, as can be seen by also looking at the next patch, "x86, ACPI: parse
ACPI_FADT_LEGACY_DEVICES" is it explicitly folds pnpbios as one of the
ACPI_FADT_LEGACY_DEVICES devices, but also paves the way for further known
main legacy components to added to the list.

> and why this structure of devices does not have the bit for the rtc device.

That's because ACPI has its own dedicated flag for it, so there already
is a one-to-one mapping available. All we needed to do to replace the
RTC hack was to provide a mechanism to unify both the paravirt RTC hack
with the ACPI RTC flag.

  Luis

  reply	other threads:[~2016-04-07 21:42 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-07  0:06 [PATCH v4 00/14] x86: remove paravirt_enabled Luis R. Rodriguez
2016-04-07  0:06 ` [PATCH v4 01/14] x86/boot: enumerate documentation for the x86 hardware_subarch Luis R. Rodriguez
2016-04-07 11:25   ` Andy Shevchenko
2016-04-07 22:36     ` Luis R. Rodriguez
2016-04-07  0:06 ` [PATCH v4 02/14] x86/xen: use X86_SUBARCH_XEN for PV guest boots Luis R. Rodriguez
2016-04-07  9:41   ` [Xen-devel] " David Vrabel
2016-04-07  0:06 ` [PATCH v4 03/14] tools/lguest: make lguest launcher use X86_SUBARCH_LGUEST explicitly Luis R. Rodriguez
2016-04-07  0:06 ` [PATCH v4 04/14] x86/rtc: replace paravirt rtc check with platform legacy quirk Luis R. Rodriguez
2016-04-07  9:42   ` [Xen-devel] " David Vrabel
2016-04-13 23:08     ` Luis R. Rodriguez
2016-04-07 12:55   ` Boris Ostrovsky
2016-04-08  0:32     ` Luis R. Rodriguez
2016-04-08  5:18       ` Juergen Gross
2016-04-08  6:29         ` Luis R. Rodriguez
2016-04-08  6:38           ` Juergen Gross
2016-04-08  6:56             ` Luis R. Rodriguez
2016-04-08  7:13               ` Juergen Gross
2016-04-08  7:36                 ` Luis R. Rodriguez
2016-04-08  7:59                   ` Juergen Gross
2016-04-08 12:37                     ` Boris Ostrovsky
2016-04-08 18:45                       ` Luis R. Rodriguez
2016-04-08 12:25           ` Boris Ostrovsky
2016-04-07  0:06 ` [PATCH v4 05/14] x86, ACPI: move ACPI_FADT_NO_CMOS_RTC check to ACPI boot code Luis R. Rodriguez
2016-04-07  0:06 ` [PATCH v4 06/14] x86/init: use a platform legacy quirk for ebda Luis R. Rodriguez
2016-04-07  9:44   ` [Xen-devel] " David Vrabel
2016-04-07 21:07     ` Luis R. Rodriguez
2016-04-07  0:06 ` [PATCH v4 07/14] tools/lguest: force disable tboot and apm Luis R. Rodriguez
2016-04-11  3:32   ` Rusty Russell
2016-04-07  0:06 ` [PATCH v4 08/14] apm32: remove paravirt_enabled() use Luis R. Rodriguez
2016-04-07 13:08   ` Boris Ostrovsky
2016-04-07 22:31     ` Luis R. Rodriguez
2016-04-07  0:06 ` [PATCH v4 09/14] x86/tboot: remove paravirt_enabled() Luis R. Rodriguez
2016-04-07  0:06 ` [PATCH v4 10/14] x86/cpu/intel: remove not needed paravirt_enabled() for f00f work around Luis R. Rodriguez
2016-04-07  0:06 ` [PATCH v4 11/14] pnpbios: replace paravirt_enabled() check with legacy device check Luis R. Rodriguez
     [not found]   ` <1459987594-5434-12-git-send-email-mcgrof-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2016-04-07  9:46     ` [Xen-devel] " David Vrabel
2016-04-07 21:42       ` Luis R. Rodriguez [this message]
2016-04-07  0:06 ` [PATCH v4 12/14] x86, ACPI: parse ACPI_FADT_LEGACY_DEVICES Luis R. Rodriguez
2016-04-07  0:06 ` [PATCH v4 13/14] x86/init: rename ebda code file Luis R. Rodriguez
2016-04-07  0:06 ` [PATCH v4 14/14] x86/paravirt: remove paravirt_enabled() Luis R. Rodriguez
2016-04-07 13:24 ` [Xen-devel] [PATCH v4 00/14] x86: remove paravirt_enabled Juergen Gross
2016-04-07 21:31 ` [PATCH v4 13/14] x86/init: rename ebda code file Luis R. Rodriguez
2016-04-08  1:14 ` [PATCH v4 00/14] x86: remove paravirt_enabled Luis R. Rodriguez
2016-04-08 10:23   ` Borislav Petkov

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=20160407214216.GH1990@wotan.suse.de \
    --to=mcgrof@kernel.org \
    --cc=andrew.cooper3@citrix.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=boris.ostrovsky@oracle.com \
    --cc=bp@alien8.de \
    --cc=david.vrabel@citrix.com \
    --cc=glin@suse.com \
    --cc=hpa@zytor.com \
    --cc=jlee@suse.com \
    --cc=josh@joshtriplett.org \
    --cc=lguest@lists.ozlabs.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luto@amacapital.net \
    --cc=lv.zheng@intel.com \
    --cc=matt@codeblueprint.co.uk \
    --cc=mingo@redhat.com \
    --cc=rafael.j.wysocki@intel.com \
    --cc=robert.moore@intel.com \
    --cc=rusty@rustcorp.com.au \
    --cc=tglx@linutronix.de \
    --cc=tiwai@suse.de \
    --cc=toshi.kani@hp.com \
    --cc=x86@kernel.org \
    --cc=xen-devel@lists.xensource.com \
    /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).