2005-10-31 23:33:12

by Chris Wright

[permalink] [raw]
Subject: [PATCH] TPM compile fix

Current tree doesn't build (at least on x86_64) due to TPM breakage:

CC drivers/char/tpm/tpm_nsc.o
drivers/char/tpm/tpm_nsc.c:277: error: `platform_bus_type' undeclared here (not in a function)
...
CC drivers/char/tpm/tpm_atmel.o
drivers/char/tpm/tpm_atmel.c:175: error: `platform_bus_type' undeclared here (not in a function)

Make sure to include proper headers.

Signed-off-by: Chris Wright <[email protected]>
---

diff --git a/drivers/char/tpm/tpm_atmel.c b/drivers/char/tpm/tpm_atmel.c
--- a/drivers/char/tpm/tpm_atmel.c
+++ b/drivers/char/tpm/tpm_atmel.c
@@ -19,6 +19,7 @@
*
*/

+#include <linux/platform_device.h>
#include "tpm.h"

/* Atmel definitions */
diff --git a/drivers/char/tpm/tpm_nsc.c b/drivers/char/tpm/tpm_nsc.c
--- a/drivers/char/tpm/tpm_nsc.c
+++ b/drivers/char/tpm/tpm_nsc.c
@@ -19,6 +19,7 @@
*
*/

+#include <linux/platform_device.h>
#include "tpm.h"

/* National definitions */


2005-11-01 14:23:56

by Kylene Jo Hall

[permalink] [raw]
Subject: Re: [PATCH] TPM compile fix

Acked-by: Kylene Hall <[email protected]>

On Mon, 2005-10-31 at 15:33 -0800, Chris Wright wrote:
> Current tree doesn't build (at least on x86_64) due to TPM breakage:
>
> CC drivers/char/tpm/tpm_nsc.o
> drivers/char/tpm/tpm_nsc.c:277: error: `platform_bus_type' undeclared here (not in a function)
> ...
> CC drivers/char/tpm/tpm_atmel.o
> drivers/char/tpm/tpm_atmel.c:175: error: `platform_bus_type' undeclared here (not in a function)
>
> Make sure to include proper headers.
>
> Signed-off-by: Chris Wright <[email protected]>
> ---
>
> diff --git a/drivers/char/tpm/tpm_atmel.c b/drivers/char/tpm/tpm_atmel.c
> --- a/drivers/char/tpm/tpm_atmel.c
> +++ b/drivers/char/tpm/tpm_atmel.c
> @@ -19,6 +19,7 @@
> *
> */
>
> +#include <linux/platform_device.h>
> #include "tpm.h"
>
> /* Atmel definitions */
> diff --git a/drivers/char/tpm/tpm_nsc.c b/drivers/char/tpm/tpm_nsc.c
> --- a/drivers/char/tpm/tpm_nsc.c
> +++ b/drivers/char/tpm/tpm_nsc.c
> @@ -19,6 +19,7 @@
> *
> */
>
> +#include <linux/platform_device.h>
> #include "tpm.h"
>
> /* National definitions */
>