From: Igor Mammedov <imammedo@redhat.com>
To: Eric DeVolder <eric.devolder@oracle.com>
Cc: ehabkost@redhat.com, mst@redhat.com, konrad.wilk@oracle.com,
qemu-devel@nongnu.org, pbonzini@redhat.com,
boris.ostrovsky@oracle.com, rth@twiddle.net
Subject: Re: [PATCH v5 08/10] ACPI ERST: create ACPI ERST table for pc/x86 machines.
Date: Mon, 26 Jul 2021 13:30:17 +0200 [thread overview]
Message-ID: <20210726133017.6b0d0031@redhat.com> (raw)
In-Reply-To: <3916035d-a628-f7e2-44f3-1a724e3d523f@oracle.com>
On Wed, 21 Jul 2021 11:16:42 -0500
Eric DeVolder <eric.devolder@oracle.com> wrote:
> On 7/20/21 8:19 AM, Igor Mammedov wrote:
> > On Wed, 30 Jun 2021 15:07:19 -0400
> > Eric DeVolder <eric.devolder@oracle.com> wrote:
> >
> >> This change exposes ACPI ERST support for x86 guests.
> >>
> >> Signed-off-by: Eric DeVolder <eric.devolder@oracle.com>
> > looks good to me, maybe move find_erst_dev() impl. here as well
> > if it's the patch it's first used.
>
> I've followed your previous suggestion of mimicking find_vmgenid_dev(), which
> declares it in its header file. I've done the same, find_erst_dev() is
> declared in its header file and used in these files.
it's fine doing like this but
it would be easier to follow if this were part of [6/10],
so that function is introduced and used in the same patch.
> >
> >> ---
> >> hw/i386/acpi-build.c | 9 +++++++++
> >> hw/i386/acpi-microvm.c | 9 +++++++++
> >> 2 files changed, 18 insertions(+)
> >>
> >> diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
> >> index de98750..d2026cc 100644
> >> --- a/hw/i386/acpi-build.c
> >> +++ b/hw/i386/acpi-build.c
> >> @@ -43,6 +43,7 @@
> >> #include "sysemu/tpm.h"
> >> #include "hw/acpi/tpm.h"
> >> #include "hw/acpi/vmgenid.h"
> >> +#include "hw/acpi/erst.h"
> >> #include "hw/boards.h"
> >> #include "sysemu/tpm_backend.h"
> >> #include "hw/rtc/mc146818rtc_regs.h"
> >> @@ -2327,6 +2328,7 @@ void acpi_build(AcpiBuildTables *tables, MachineState *machine)
> >> GArray *tables_blob = tables->table_data;
> >> AcpiSlicOem slic_oem = { .id = NULL, .table_id = NULL };
> >> Object *vmgenid_dev;
> >> + Object *erst_dev;
> >> char *oem_id;
> >> char *oem_table_id;
> >>
> >> @@ -2388,6 +2390,13 @@ void acpi_build(AcpiBuildTables *tables, MachineState *machine)
> >> ACPI_DEVICE_IF(x86ms->acpi_dev), x86ms->oem_id,
> >> x86ms->oem_table_id);
> >>
> >> + erst_dev = find_erst_dev();
> >> + if (erst_dev) {
> >> + acpi_add_table(table_offsets, tables_blob);
> >> + build_erst(tables_blob, tables->linker, erst_dev,
> >> + x86ms->oem_id, x86ms->oem_table_id);
> >> + }
> >> +
> >> vmgenid_dev = find_vmgenid_dev();
> >> if (vmgenid_dev) {
> >> acpi_add_table(table_offsets, tables_blob);
> >> diff --git a/hw/i386/acpi-microvm.c b/hw/i386/acpi-microvm.c
> >> index ccd3303..0099b13 100644
> >> --- a/hw/i386/acpi-microvm.c
> >> +++ b/hw/i386/acpi-microvm.c
> >> @@ -30,6 +30,7 @@
> >> #include "hw/acpi/bios-linker-loader.h"
> >> #include "hw/acpi/generic_event_device.h"
> >> #include "hw/acpi/utils.h"
> >> +#include "hw/acpi/erst.h"
> >> #include "hw/boards.h"
> >> #include "hw/i386/fw_cfg.h"
> >> #include "hw/i386/microvm.h"
> >> @@ -160,6 +161,7 @@ static void acpi_build_microvm(AcpiBuildTables *tables,
> >> X86MachineState *x86ms = X86_MACHINE(mms);
> >> GArray *table_offsets;
> >> GArray *tables_blob = tables->table_data;
> >> + Object *erst_dev;
> >> unsigned dsdt, xsdt;
> >> AcpiFadtData pmfadt = {
> >> /* ACPI 5.0: 4.1 Hardware-Reduced ACPI */
> >> @@ -209,6 +211,13 @@ static void acpi_build_microvm(AcpiBuildTables *tables,
> >> ACPI_DEVICE_IF(x86ms->acpi_dev), x86ms->oem_id,
> >> x86ms->oem_table_id);
> >>
> >> + erst_dev = find_erst_dev();
> >> + if (erst_dev) {
> >> + acpi_add_table(table_offsets, tables_blob);
> >> + build_erst(tables_blob, tables->linker, erst_dev,
> >> + x86ms->oem_id, x86ms->oem_table_id);
> >> + }
> >> +
> >> xsdt = tables_blob->len;
> >> build_xsdt(tables_blob, tables->linker, table_offsets, x86ms->oem_id,
> >> x86ms->oem_table_id);
> >
>
next prev parent reply other threads:[~2021-07-26 11:32 UTC|newest]
Thread overview: 58+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-30 19:07 [PATCH v5 00/10] acpi: Error Record Serialization Table, ERST, support for QEMU Eric DeVolder
2021-06-30 19:07 ` [PATCH v5 01/10] ACPI ERST: bios-tables-test.c steps 1 and 2 Eric DeVolder
2021-06-30 19:07 ` [PATCH v5 02/10] ACPI ERST: specification for ERST support Eric DeVolder
2021-06-30 19:26 ` Eric DeVolder
2021-07-19 15:02 ` Igor Mammedov
2021-07-21 15:42 ` Eric DeVolder
2021-07-26 10:06 ` Igor Mammedov
2021-07-26 19:52 ` Eric DeVolder
2021-07-27 11:45 ` Igor Mammedov
2021-07-28 15:16 ` Eric DeVolder
2021-06-30 19:07 ` [PATCH v5 03/10] ACPI ERST: PCI device_id for ERST Eric DeVolder
2021-07-19 15:06 ` Igor Mammedov
2021-07-21 15:42 ` Eric DeVolder
2021-06-30 19:07 ` [PATCH v5 04/10] ACPI ERST: header file " Eric DeVolder
2021-06-30 19:07 ` [PATCH v5 05/10] ACPI ERST: support for ACPI ERST feature Eric DeVolder
2021-07-20 12:17 ` Igor Mammedov
2021-07-21 16:07 ` Eric DeVolder
2021-07-26 10:42 ` Igor Mammedov
2021-07-26 20:01 ` Eric DeVolder
2021-07-27 12:52 ` Igor Mammedov
2021-08-04 22:13 ` Eric DeVolder
2021-08-05 9:05 ` Igor Mammedov
2021-07-21 17:36 ` Eric DeVolder
2021-07-26 10:13 ` Igor Mammedov
2021-06-30 19:07 ` [PATCH v5 06/10] ACPI ERST: build the ACPI ERST table Eric DeVolder
2021-07-20 13:16 ` Igor Mammedov
2021-07-20 14:59 ` Igor Mammedov
2021-07-21 16:12 ` Eric DeVolder
2021-07-26 11:00 ` Igor Mammedov
2021-07-26 20:02 ` Eric DeVolder
2021-07-27 12:01 ` Igor Mammedov
2021-07-28 15:18 ` Eric DeVolder
2021-06-30 19:07 ` [PATCH v5 07/10] ACPI ERST: trace support Eric DeVolder
2021-07-20 13:15 ` Igor Mammedov
2021-07-21 16:14 ` Eric DeVolder
2021-07-26 11:08 ` Igor Mammedov
2021-07-26 20:03 ` Eric DeVolder
2021-06-30 19:07 ` [PATCH v5 08/10] ACPI ERST: create ACPI ERST table for pc/x86 machines Eric DeVolder
2021-07-20 13:19 ` Igor Mammedov
2021-07-21 16:16 ` Eric DeVolder
2021-07-26 11:30 ` Igor Mammedov [this message]
2021-07-26 20:03 ` Eric DeVolder
2021-06-30 19:07 ` [PATCH v5 09/10] ACPI ERST: qtest for ERST Eric DeVolder
2021-07-20 13:38 ` Igor Mammedov
2021-07-21 16:18 ` Eric DeVolder
2021-07-26 11:45 ` Igor Mammedov
2021-07-26 20:06 ` Eric DeVolder
2021-06-30 19:07 ` [PATCH v5 10/10] ACPI ERST: step 6 of bios-tables-test.c Eric DeVolder
2021-07-20 13:24 ` Igor Mammedov
2021-07-21 16:19 ` Eric DeVolder
2021-07-13 20:38 ` [PATCH v5 00/10] acpi: Error Record Serialization Table, ERST, support for QEMU Michael S. Tsirkin
2021-07-21 15:23 ` Eric DeVolder
2021-07-20 14:57 ` Igor Mammedov
2021-07-21 15:26 ` Eric DeVolder
2021-07-23 16:26 ` Eric DeVolder
2021-07-27 12:55 ` Igor Mammedov
2021-07-28 15:19 ` Eric DeVolder
2021-07-29 8:07 ` Igor Mammedov
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=20210726133017.6b0d0031@redhat.com \
--to=imammedo@redhat.com \
--cc=boris.ostrovsky@oracle.com \
--cc=ehabkost@redhat.com \
--cc=eric.devolder@oracle.com \
--cc=konrad.wilk@oracle.com \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=rth@twiddle.net \
/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).