[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v4 1/2] tpm: convert tpmdev options processing to new visitor
From: |
James Bottomley |
Subject: |
Re: [PATCH v4 1/2] tpm: convert tpmdev options processing to new visitor format |
Date: |
Fri, 30 Dec 2022 22:40:05 -0500 |
User-agent: |
Evolution 3.42.4 |
On Fri, 2022-12-30 at 12:01 -0500, Stefan Berger wrote:
> On 12/30/22 10:24, James Bottomley wrote:
[...]
> > @@ -2906,9 +2893,7 @@ void qemu_init(int argc, char **argv)
> > break;
> > #ifdef CONFIG_TPM
> > case QEMU_OPTION_tpmdev:
> > - if (tpm_config_parse(qemu_find_opts("tpmdev"),
> > optarg) < 0) {
> > - exit(1);
> > - }
> > + tpm_config_parse(optarg);
>
> The patches don't apply to upstream's master.
I think it depends how you apply them. If you use git, they do except
a minor merge conflict in tpm_passthrough.c
More seriously there's now a compile failure in tpm_mssim.c because of
the lost has_X for X pointer options, but it's also easily fixable.
> This used to exit() on failure but doesn't do this anymore, though it
> probably should.
Actually it still does. I converted it to the standard &error_fatal
way of doing this, which will cause an exit(1) if we get an error. The
error_fatal construct seems to have been done precisely to cure this
type of return value threading.
James