diff mbox

[for-4.8,2/2] libxc: set rsdp pointer for PVHv2 guests

Message ID 1478519704-19543-3-git-send-email-roger.pau@citrix.com (mailing list archive)
State New, archived
Headers show

Commit Message

Roger Pau Monne Nov. 7, 2016, 11:55 a.m. UTC
Set the address of the RSDP in the HVM start info structure for PVHv2 DomUs
that have ACPI tables.

Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
---
Cc: Ian Jackson <ian.jackson@eu.citrix.com>
Cc: Wei Liu <wei.liu2@citrix.com>
Cc: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
---
 tools/libxc/xc_dom_x86.c | 3 +++
 1 file changed, 3 insertions(+)

Comments

Boris Ostrovsky Nov. 7, 2016, 2:40 p.m. UTC | #1
On 11/07/2016 06:55 AM, Roger Pau Monne wrote:
> Set the address of the RSDP in the HVM start info structure for PVHv2 DomUs
> that have ACPI tables.
>
> Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
> ---
> Cc: Ian Jackson <ian.jackson@eu.citrix.com>
> Cc: Wei Liu <wei.liu2@citrix.com>
> Cc: Boris Ostrovsky <boris.ostrovsky@oracle.com>
> Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
> ---
>  tools/libxc/xc_dom_x86.c | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/tools/libxc/xc_dom_x86.c b/tools/libxc/xc_dom_x86.c
> index 0eab8a7..0f52520 100644
> --- a/tools/libxc/xc_dom_x86.c
> +++ b/tools/libxc/xc_dom_x86.c
> @@ -1797,6 +1797,9 @@ static int bootlate_hvm(struct xc_dom_image *dom)
>              modlist[0].size = dom->ramdisk_seg.vend - dom->ramdisk_seg.vstart;
>              start_info->nr_modules = 1;
>          }
> +
> +        /* Module 0 is the RSDP */

I'd say "ACPI module 0" because modlist (right above the comment) also
operates on modules and that may confuse people (it did for me).

-boris

> +        start_info->rsdp_paddr = dom->acpi_modules[0].guest_addr_out ? : 0;
>      }
>      else
>      {
diff mbox

Patch

diff --git a/tools/libxc/xc_dom_x86.c b/tools/libxc/xc_dom_x86.c
index 0eab8a7..0f52520 100644
--- a/tools/libxc/xc_dom_x86.c
+++ b/tools/libxc/xc_dom_x86.c
@@ -1797,6 +1797,9 @@  static int bootlate_hvm(struct xc_dom_image *dom)
             modlist[0].size = dom->ramdisk_seg.vend - dom->ramdisk_seg.vstart;
             start_info->nr_modules = 1;
         }
+
+        /* Module 0 is the RSDP */
+        start_info->rsdp_paddr = dom->acpi_modules[0].guest_addr_out ? : 0;
     }
     else
     {