qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH V8 14/14] Allow to provide inital TPM state


From: Stefan Berger
Subject: Re: [Qemu-devel] [PATCH V8 14/14] Allow to provide inital TPM state
Date: Wed, 07 Sep 2011 09:51:00 -0400
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.18) Gecko/20110621 Fedora/3.1.11-1.fc14 Lightning/1.0b3pre Thunderbird/3.1.11

On 09/07/2011 07:23 AM, Michael S. Tsirkin wrote:
On Tue, Sep 06, 2011 at 10:45:34PM -0400, Stefan Berger wrote:
On 09/04/2011 12:38 PM, Michael S. Tsirkin wrote:
On Thu, Sep 01, 2011 at 11:00:56PM -0400, Stefan Berger wrote:

initstate_fd=<file descriptor>
initstate_base64=on/off (or base64/bin if you really expect
        more formats in the future)

and use qemu routines to get the fd so they can be
passed through the monitor later ...

I suppose you mean monitor_get_fd(). That functions seems to only be
used by net.c so far and if  understand the chain of functions
correctly that are called with the monitor as parameter it helps in
hotplugging net devices ? For the TPM I would like to *not* have
support for hotplugging since that device is supposed to be soldered
to the motherboard and needs to be initialized through a command
sequence by the (v)BIOS, so it has to be present early on during
machine startup.

   Stefan
Fine, but let's reuse common functions and save code duplication,
especially parsing functions.

When parsing the command line there's no Monitor being passed around. So in case of 'net' net_handle_fd_param() (net.c) ends up not invoking monitor_get_fd() but the else branch where strtol() is used to convert the fd. Now I won't call net_handle_fd_param() but could introduce tpm_handle_fd_param() also calling strtol(). Though that would not make me call a common function but duplicating the code there... I don't know of another function handling the parsing of fd's. Is there one ? If not, I'll also just fall back to using strtol().

  Stefan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]