From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757578AbcBSNki (ORCPT ); Fri, 19 Feb 2016 08:40:38 -0500 Received: from smtp.citrix.com ([66.165.176.89]:65392 "EHLO SMTP.CITRIX.COM" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756625AbcBSNkg (ORCPT ); Fri, 19 Feb 2016 08:40:36 -0500 X-IronPort-AV: E=Sophos;i="5.22,470,1449532800"; d="scan'208";a="332873658" Subject: Re: [Xen-devel] [PATCH 1/9] x86/boot: enumerate documentation for the x86 hardware_subarch To: "Luis R. Rodriguez" , References: <1455887316-9223-1-git-send-email-mcgrof@kernel.org> <1455887316-9223-2-git-send-email-mcgrof@kernel.org> CC: , , , , , , , Andy Shevchenko From: David Vrabel X-Enigmail-Draft-Status: N1110 Message-ID: <56C71B51.20109@citrix.com> Date: Fri, 19 Feb 2016 13:40:33 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Icedove/38.5.0 MIME-Version: 1.0 In-Reply-To: <1455887316-9223-2-git-send-email-mcgrof@kernel.org> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit X-DLP: MIA1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 19/02/16 13:08, Luis R. Rodriguez wrote: > Although hardware_subarch has been in place since the x86 boot > protocol 2.07 it hasn't been used much. Enumerate current possible > values to avoid misuses and help with semantics later at boot > time should this be used further. > > Cc: Andy Shevchenko > Signed-off-by: Luis R. Rodriguez > --- > arch/x86/include/uapi/asm/bootparam.h | 32 +++++++++++++++++++++++++++++++- > 1 file changed, 31 insertions(+), 1 deletion(-) > > diff --git a/arch/x86/include/uapi/asm/bootparam.h b/arch/x86/include/uapi/asm/bootparam.h > index 329254373479..dbfb9406436b 100644 > --- a/arch/x86/include/uapi/asm/bootparam.h > +++ b/arch/x86/include/uapi/asm/bootparam.h > @@ -157,7 +157,37 @@ struct boot_params { > __u8 _pad9[276]; /* 0xeec */ > } __attribute__((packed)); > > -enum { > +/** > + * enum x86_hardware_subarch - x86 hardware subarchitecture > + * > + * The x86 hardware_subarch and hardware_subarch_data were added as of the x86 > + * boot protocol 2.07 to help distinguish and supports custom x86 boot > + * sequences. This enum represents accepted values for the x86 > + * hardware_subarch. Custom x86 boot sequences (not X86_SUBARCH_PC) do not have > + * or simply do not make use of natural stubs like BIOS or EFI, the > + * hardware_subarch can be used on the Linux entry path to revector to a > + * subarchitecture stub when needed. This subarchitecture stub can be used to > + * set up Linux boot parameters or for special care to account for nonstandard > + * handling of page tables. This documentation reads like a plan for future implementation. Is this the level of documentation that is needed here? Also, "revector to a subarchitecture stub" is a rather odd way of saying "call a subarch-specific stub". David