From: Ilias Apalodimas <ilias.apalodimas@linaro.org>
To: Sughosh Ganu <sughosh.ganu@linaro.org>
Cc: u-boot@lists.denx.de, Simon Glass <sjg@chromium.org>,
Heinrich Schuchardt <xypron.glpk@gmx.de>
Subject: Re: [PATCH v3 2/8] tpm: Fix the return type of tpm_startup
Date: Wed, 9 Mar 2022 09:37:11 +0200 [thread overview]
Message-ID: <YihZJ4KyNPMyZizp@hades> (raw)
In-Reply-To: <20220304133429.1047752-3-sughosh.ganu@linaro.org>
On Fri, Mar 04, 2022 at 07:04:23PM +0530, Sughosh Ganu wrote:
> The tpm_startup function returns negative values for error
> conditions. Fix the return type of the function to a signed int
> instead of a u32.
>
> Signed-off-by: Sughosh Ganu <sughosh.ganu@linaro.org>
> Reviewed-by: Simon Glass <sjg@chromium.org>
> ---
>
> Changes since V2: None
>
> include/tpm_api.h | 2 +-
> lib/tpm_api.c | 3 ++-
> 2 files changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/include/tpm_api.h b/include/tpm_api.h
> index 249a966942..4d77a49719 100644
> --- a/include/tpm_api.h
> +++ b/include/tpm_api.h
> @@ -18,7 +18,7 @@
> * @param mode TPM startup mode
> * Return: return code of the operation
> */
> -u32 tpm_startup(struct udevice *dev, enum tpm_startup_type mode);
> +int tpm_startup(struct udevice *dev, enum tpm_startup_type mode);
>
> /**
> * Issue a TPM_SelfTestFull command.
> diff --git a/lib/tpm_api.c b/lib/tpm_api.c
> index 7d26ea2c3a..da48058abe 100644
> --- a/lib/tpm_api.c
> +++ b/lib/tpm_api.c
> @@ -11,7 +11,8 @@
> #include <tpm-v2.h>
> #include <tpm_api.h>
>
> -u32 tpm_startup(struct udevice *dev, enum tpm_startup_type mode)
> +
> +int tpm_startup(struct udevice *dev, enum tpm_startup_type mode)
> {
> if (tpm_is_v1(dev)) {
> return tpm1_startup(dev, mode);
> --
> 2.25.1
>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
next prev parent reply other threads:[~2022-03-09 7:37 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-04 13:34 [PATCH v3 0/8] tpm: rng: Move TPM RNG functionality to driver model Sughosh Ganu
2022-03-04 13:34 ` [PATCH v3 1/8] tpm: rng: Change tpm_get_random to return an int Sughosh Ganu
2022-03-09 7:36 ` Ilias Apalodimas
2022-03-04 13:34 ` [PATCH v3 2/8] tpm: Fix the return type of tpm_startup Sughosh Ganu
2022-03-09 7:37 ` Ilias Apalodimas [this message]
2022-03-04 13:34 ` [PATCH v3 3/8] tpm: rng: Add driver model interface for TPM RNG device Sughosh Ganu
2022-03-09 2:35 ` Simon Glass
2022-03-09 6:00 ` Sughosh Ganu
2022-03-09 11:18 ` Sughosh Ganu
2022-03-12 17:59 ` Simon Glass
2022-03-04 13:34 ` [PATCH v3 4/8] tpm: Add the RNG child device Sughosh Ganu
2022-03-09 2:35 ` Simon Glass
2022-03-09 6:02 ` Sughosh Ganu
2022-03-04 13:34 ` [PATCH v3 5/8] qemu: arm: Remove platform specific function to get RNG device Sughosh Ganu
2022-03-09 2:35 ` Simon Glass
2022-03-09 7:47 ` Ilias Apalodimas
2022-03-04 13:34 ` [PATCH v3 6/8] cmd: rng: Add support for selecting " Sughosh Ganu
2022-03-09 2:35 ` Simon Glass
2022-03-09 6:04 ` Sughosh Ganu
2022-03-09 7:42 ` Ilias Apalodimas
2022-03-09 15:32 ` Simon Glass
2022-03-10 12:42 ` Sughosh Ganu
2022-03-12 17:59 ` Simon Glass
2022-03-04 13:34 ` [PATCH v3 7/8] doc: rng: Add documentation for the rng command Sughosh Ganu
2022-03-09 2:35 ` Simon Glass
2022-03-09 7:39 ` Ilias Apalodimas
2022-03-04 13:34 ` [PATCH v3 8/8] test: rng: Add a UT testcase " Sughosh Ganu
2022-03-09 2:35 ` Simon Glass
2022-03-09 6:18 ` Sughosh Ganu
2022-03-12 2:43 ` Simon Glass
2022-03-13 11:07 ` Sughosh Ganu
2022-03-13 22:23 ` Simon Glass
2022-03-24 16:22 ` Sughosh Ganu
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=YihZJ4KyNPMyZizp@hades \
--to=ilias.apalodimas@linaro.org \
--cc=sjg@chromium.org \
--cc=sughosh.ganu@linaro.org \
--cc=u-boot@lists.denx.de \
--cc=xypron.glpk@gmx.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.