From: tip-bot for Juergen Gross <tipbot@zytor.com>
To: linux-tip-commits@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, peterz@infradead.org,
torvalds@linux-foundation.org, jgross@suse.com,
roger.pau@citrix.com, tglx@linutronix.de, mingo@kernel.org,
hpa@zytor.com
Subject: [tip:x86/boot] x86/boot: Add the ACPI RSDP address to struct setup_header::acpi_rdsp_addr
Date: Tue, 12 Dec 2017 02:53:46 -0800 [thread overview]
Message-ID: <tip-2f74cbf947f45fa082dda8eac1a1f1299a372f49@git.kernel.org> (raw)
In-Reply-To: <20171208151139.30213-2-jgross@suse.com>
Commit-ID: 2f74cbf947f45fa082dda8eac1a1f1299a372f49
Gitweb: https://git.kernel.org/tip/2f74cbf947f45fa082dda8eac1a1f1299a372f49
Author: Juergen Gross <jgross@suse.com>
AuthorDate: Fri, 8 Dec 2017 16:11:36 +0100
Committer: Ingo Molnar <mingo@kernel.org>
CommitDate: Mon, 11 Dec 2017 15:14:20 +0100
x86/boot: Add the ACPI RSDP address to struct setup_header::acpi_rdsp_addr
Xen PVH guests receive the address of the RSDP table from Xen. In order
to support booting a Xen PVH guest via Grub2 using the standard x86
boot entry we need a way for Grub2 to pass the RSDP address to the
kernel.
For this purpose expand the struct setup_header to hold the physical
address of the RSDP address. Being zero means it isn't specified and
has to be located the legacy way (searching through low memory or
EBDA).
While documenting the new setup_header layout and protocol version
2.14 add the missing documentation of protocol version 2.13.
Signed-off-by: Juergen Gross <jgross@suse.com>
Reviewed-by: Roger Pau Monné <roger.pau@citrix.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: boris.ostrovsky@oracle.com
Cc: corbet@lwn.net
Cc: lenb@kernel.org
Cc: linux-acpi@vger.kernel.org
Cc: rjw@rjwysocki.net
Cc: xen-devel@lists.xenproject.org
Link: http://lkml.kernel.org/r/20171208151139.30213-2-jgross@suse.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
---
Documentation/x86/boot.txt | 19 +++++++++++++++++++
| 6 +++++-
arch/x86/include/uapi/asm/bootparam.h | 1 +
3 files changed, 25 insertions(+), 1 deletion(-)
diff --git a/Documentation/x86/boot.txt b/Documentation/x86/boot.txt
index 5e9b826..cec1129 100644
--- a/Documentation/x86/boot.txt
+++ b/Documentation/x86/boot.txt
@@ -61,6 +61,13 @@ Protocol 2.12: (Kernel 3.8) Added the xloadflags field and extension fields
to struct boot_params for loading bzImage and ramdisk
above 4G in 64bit.
+Protocol 2.13: (Kernel 3.14) Support 32- and 64-bit flags being set in
+ xloadflags to support booting a 64-bit kernel from 32-bit
+ EFI
+
+Protocol 2.14 (Kernel 4.16) Added acpi_rsdp_addr holding the physical
+ address of the ACPI RSDP table.
+
**** MEMORY LAYOUT
The traditional memory map for the kernel loader, used for Image or
@@ -197,6 +204,7 @@ Offset Proto Name Meaning
0258/8 2.10+ pref_address Preferred loading address
0260/4 2.10+ init_size Linear memory required during initialization
0264/4 2.11+ handover_offset Offset of handover entry point
+0268/8 2.14+ acpi_rsdp_addr Physical address of RSDP table
(1) For backwards compatibility, if the setup_sects field contains 0, the
real value is 4.
@@ -744,6 +752,17 @@ Offset/size: 0x264/4
See EFI HANDOVER PROTOCOL below for more details.
+Field name: acpi_rsdp_addr
+Type: write
+Offset/size: 0x268/8
+Protocol: 2.14+
+
+ This field can be set by the boot loader to tell the kernel the
+ physical address of the ACPI RSDP table.
+
+ A value of 0 indicates the kernel should fall back to the standard
+ methods to locate the RSDP.
+
**** THE IMAGE CHECKSUM
--git a/arch/x86/boot/header.S b/arch/x86/boot/header.S
index 850b876..4c881c8 100644
--- a/arch/x86/boot/header.S
+++ b/arch/x86/boot/header.S
@@ -300,7 +300,7 @@ _start:
# Part 2 of the header, from the old setup.S
.ascii "HdrS" # header signature
- .word 0x020d # header version number (>= 0x0105)
+ .word 0x020e # header version number (>= 0x0105)
# or else old loadlin-1.5 will fail)
.globl realmode_swtch
realmode_swtch: .word 0, 0 # default_switch, SETUPSEG
@@ -558,6 +558,10 @@ pref_address: .quad LOAD_PHYSICAL_ADDR # preferred load addr
init_size: .long INIT_SIZE # kernel initialization size
handover_offset: .long 0 # Filled in by build.c
+acpi_rsdp_addr: .quad 0 # 64-bit physical pointer to the
+ # ACPI RSDP table, added with
+ # version 2.14
+
# End of setup header #####################################################
.section ".entrytext", "ax"
diff --git a/arch/x86/include/uapi/asm/bootparam.h b/arch/x86/include/uapi/asm/bootparam.h
index afdd5ae..5742e43 100644
--- a/arch/x86/include/uapi/asm/bootparam.h
+++ b/arch/x86/include/uapi/asm/bootparam.h
@@ -85,6 +85,7 @@ struct setup_header {
__u64 pref_address;
__u32 init_size;
__u32 handover_offset;
+ __u64 acpi_rsdp_addr;
} __attribute__((packed));
struct sys_desc_table {
next prev parent reply other threads:[~2017-12-12 10:57 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-08 15:11 [PATCH v3 0/4] x86: make rsdp address accessible via boot params Juergen Gross
2017-12-08 15:11 ` [PATCH v3 1/4] x86/boot: add acpi rsdp address to setup_header Juergen Gross
2017-12-12 10:53 ` tip-bot for Juergen Gross [this message]
2017-12-08 15:11 ` [PATCH v3 2/4] x86/acpi: take rsdp address for boot params if available Juergen Gross
2017-12-12 10:54 ` [tip:x86/boot] x86/acpi: Take the RSDP address for boot parameters " tip-bot for Juergen Gross
2017-12-08 15:11 ` [PATCH v3 3/4] x86/xen: fix boot loader version reported for pvh guests Juergen Gross
2017-12-12 10:54 ` [tip:x86/boot] x86/xen: Fix the boot loader version reported for PVH guests tip-bot for Juergen Gross
2017-12-08 15:11 ` [PATCH v3 4/4] x86/xen: supply rsdp address in boot params for pvh guests Juergen Gross
2017-12-11 10:09 ` [Xen-devel] " Jan Beulich
[not found] ` <5A2E674C0200007800196522@suse.com>
2017-12-11 10:51 ` Juergen Gross
2017-12-11 14:14 ` Ingo Molnar
2017-12-12 10:55 ` [tip:x86/boot] x86/xen: Supply RSDP address in boot params for PVH guests tip-bot for Juergen Gross
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=tip-2f74cbf947f45fa082dda8eac1a1f1299a372f49@git.kernel.org \
--to=tipbot@zytor.com \
--cc=hpa@zytor.com \
--cc=jgross@suse.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=peterz@infradead.org \
--cc=roger.pau@citrix.com \
--cc=tglx@linutronix.de \
--cc=torvalds@linux-foundation.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