From: Laszlo Ersek <lersek@redhat.com>
To: "Marc-André Lureau" <marcandre.lureau@gmail.com>,
"Dr. David Alan Gilbert" <dgilbert@redhat.com>
Cc: Eduardo Habkost <ehabkost@redhat.com>,
"Michael S. Tsirkin" <mst@redhat.com>,
Stefan Berger <stefanb@linux.vnet.ibm.com>,
QEMU <qemu-devel@nongnu.org>, Paolo Bonzini <pbonzini@redhat.com>,
Igor Mammedov <imammedo@redhat.com>,
Richard Henderson <rth@twiddle.net>,
Alex Williamson <alex.williamson@redhat.com>
Subject: Re: [Qemu-devel] [PATCH v10 6/6] tpm: add ACPI memory clear interface
Date: Tue, 11 Sep 2018 16:19:13 +0200 [thread overview]
Message-ID: <c2824184-8e20-259d-bae1-b54d054757d0@redhat.com> (raw)
In-Reply-To: <CAJ+F1CJEnLkJo29eahWS6F1cRyvS1nJZy-kGvQH04mGZdntbCw@mail.gmail.com>
+Alex, due to mention of 21e00fa55f3fd
On 09/10/18 15:03, Marc-André Lureau wrote:
> Hi
>
> On Mon, Sep 10, 2018 at 2:44 PM Dr. David Alan Gilbert
> <dgilbert@redhat.com> wrote:
>> (I didn't know about guest_phys_block* and would have probably just used
>> qemu_ram_foreach_block )
>>
>
> guest_phys_block*() seems to fit, as it lists only the blocks actually
> used, and already skip the device RAM.
>
> Laszlo, you wrote the functions
> (https://git.qemu.org/?p=qemu.git;a=commit;h=c5d7f60f0614250bd925071e25220ce5958f75d0),
> do you think it's appropriate to list the memory to clear, or we
> should rather use qemu_ram_foreach_block() ?
Originally, I would have said, "use either, doesn't matter". Namely,
when I introduced the guest_phys_block*() functions, the original
purpose was not related to RAM *contents*, but to RAM *addresses*
(GPAs). This is evident if you look at the direct child commit of
c5d7f60f0614, namely 56c4bfb3f07f, which put GuestPhysBlockList to use.
And, for your use case (= wiping RAM), GPAs don't matter, only contents
matter.
However, with the commits I mentioned previously, namely e4dc3f5909ab9
and 21e00fa55f3fd, we now filter out some RAM blocks from the dumping
based on contents / backing as well. I think? So I believe we should
honor that for the wiping to. I guess I'd (vaguely) suggest using
guest_phys_block*().
(And then, as Dave suggests, maybe extend the filter to consider pmem
too, separately.)
Laszlo
prev parent reply other threads:[~2018-09-11 14:19 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-31 17:24 [Qemu-devel] [PATCH v10 0/6] Add support for TPM Physical Presence interface Marc-André Lureau
2018-08-31 17:24 ` [Qemu-devel] [PATCH v10 1/6] hw/i386: add pc-i440fx-3.1 & pc-q35-3.1 Marc-André Lureau
2018-08-31 17:24 ` [Qemu-devel] [PATCH v10 2/6] tpm: add a "ppi" boolean property Marc-André Lureau
2018-08-31 17:24 ` [Qemu-devel] [PATCH v10 3/6] tpm: allocate/map buffer for TPM Physical Presence interface Marc-André Lureau
2018-08-31 23:28 ` Marc-André Lureau
2018-09-03 21:48 ` Juan Quintela
2018-09-04 6:51 ` Igor Mammedov
2018-09-05 8:21 ` Marc-André Lureau
2018-09-05 8:36 ` Juan Quintela
2018-09-05 9:17 ` Igor Mammedov
2018-08-31 17:24 ` [Qemu-devel] [PATCH v10 4/6] acpi: expose TPM/PPI configuration parameters to firmware via fw_cfg Marc-André Lureau
2018-08-31 17:24 ` [Qemu-devel] [PATCH v10 5/6] acpi: build TPM Physical Presence interface Marc-André Lureau
2018-08-31 17:24 ` [Qemu-devel] [PATCH v10 6/6] tpm: add ACPI memory clear interface Marc-André Lureau
2018-09-04 6:46 ` Igor Mammedov
2018-09-06 3:50 ` Marc-André Lureau
2018-09-06 7:58 ` Igor Mammedov
2018-09-06 8:01 ` Marc-André Lureau
2018-09-06 8:40 ` Igor Mammedov
2018-09-06 8:59 ` Dr. David Alan Gilbert
2018-09-06 9:11 ` Marc-André Lureau
2018-09-06 9:42 ` Dr. David Alan Gilbert
2018-09-06 16:50 ` Marc-André Lureau
2018-09-06 17:23 ` Dr. David Alan Gilbert
2018-09-06 18:58 ` Laszlo Ersek
2018-09-10 10:44 ` Dr. David Alan Gilbert
2018-09-10 13:03 ` Marc-André Lureau
2018-09-11 14:19 ` Laszlo Ersek [this message]
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=c2824184-8e20-259d-bae1-b54d054757d0@redhat.com \
--to=lersek@redhat.com \
--cc=alex.williamson@redhat.com \
--cc=dgilbert@redhat.com \
--cc=ehabkost@redhat.com \
--cc=imammedo@redhat.com \
--cc=marcandre.lureau@gmail.com \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=rth@twiddle.net \
--cc=stefanb@linux.vnet.ibm.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).