[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1549234854.4146.24.camel@linux.ibm.com>
Date: Sun, 03 Feb 2019 18:00:54 -0500
From: Mimi Zohar <zohar@...ux.ibm.com>
To: Jarkko Sakkinen <jarkko.sakkinen@...ux.intel.com>,
linux-integrity@...r.kernel.org
Cc: linux-kernel@...r.kernel.org,
linux-security-module@...r.kernel.org, roberto.sassu@...wei.com,
stable@...r.kernel.org
Subject: Re: [PATCH] tpm/st33zp24: Fix name collision with TPM_BUFSIZE
Hi Jarkko,
On Fri, 2019-02-01 at 19:41 +0200, Jarkko Sakkinen wrote:
> Rename TPM_BUFSIZE defined in drivers/char/tpm/st33zp24/st33zp24.h to
> ST33ZP24_BUFSIZE as it collides with TPM_BUFSIZE defined in
> drivers/char/tpm/tpm.h.
>
> Cc: stable@...r.kernel.org
> Fixes: bf38b8710892 ("tpm/tpm_i2c_stm_st33: Split tpm_i2c_tpm_st33 in 2 layers (core + phy)")
> Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@...ux.intel.com>
FYI, I'm seeing a similar redefined TPM_BUFSIZE in tpm_i2c_infineon.c.
Mimi
> ---
> drivers/char/tpm/st33zp24/i2c.c | 2 +-
> drivers/char/tpm/st33zp24/spi.c | 2 +-
> drivers/char/tpm/st33zp24/st33zp24.h | 4 ++--
> 3 files changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/char/tpm/st33zp24/i2c.c b/drivers/char/tpm/st33zp24/i2c.c
> index be5d1abd3e8e..8390c5b54c3b 100644
> --- a/drivers/char/tpm/st33zp24/i2c.c
> +++ b/drivers/char/tpm/st33zp24/i2c.c
> @@ -33,7 +33,7 @@
>
> struct st33zp24_i2c_phy {
> struct i2c_client *client;
> - u8 buf[TPM_BUFSIZE + 1];
> + u8 buf[ST33ZP24_BUFSIZE + 1];
> int io_lpcpd;
> };
>
> diff --git a/drivers/char/tpm/st33zp24/spi.c b/drivers/char/tpm/st33zp24/spi.c
> index d7909ab287a8..ff019a1e3c68 100644
> --- a/drivers/char/tpm/st33zp24/spi.c
> +++ b/drivers/char/tpm/st33zp24/spi.c
> @@ -63,7 +63,7 @@
> * some latency byte before the answer is available (max 15).
> * We have 2048 + 1024 + 15.
> */
> -#define ST33ZP24_SPI_BUFFER_SIZE (TPM_BUFSIZE + (TPM_BUFSIZE / 2) +\
> +#define ST33ZP24_SPI_BUFFER_SIZE (ST33ZP24_BUFSIZE + (ST33ZP24_BUFSIZE / 2) +\
> MAX_SPI_LATENCY)
>
>
> diff --git a/drivers/char/tpm/st33zp24/st33zp24.h b/drivers/char/tpm/st33zp24/st33zp24.h
> index 6f4a4198af6a..20da0a84988d 100644
> --- a/drivers/char/tpm/st33zp24/st33zp24.h
> +++ b/drivers/char/tpm/st33zp24/st33zp24.h
> @@ -18,8 +18,8 @@
> #ifndef __LOCAL_ST33ZP24_H__
> #define __LOCAL_ST33ZP24_H__
>
> -#define TPM_WRITE_DIRECTION 0x80
> -#define TPM_BUFSIZE 2048
> +#define TPM_WRITE_DIRECTION 0x80
> +#define ST33ZP24_BUFSIZE 2048
>
> struct st33zp24_dev {
> struct tpm_chip *chip;
Powered by blists - more mailing lists