* [PATCH] TPM TIS device driver locality request
@ 2007-11-18 23:32 Marcel Selhorst
2007-11-20 6:23 ` Andrew Morton
0 siblings, 1 reply; 3+ messages in thread
From: Marcel Selhorst @ 2007-11-18 23:32 UTC (permalink / raw)
To: Andrew Morton; +Cc: TPM Device Driver List, linux-kernel, Kylene Jo Hall
Dear all,
during the initialization of the TPM TIS driver, the necessary
locality has to be requested earlier in the init-process. Depending on
the used TPM chip, this leads to wrong information.
For example: Lenovo X61s with Atmel TPM:
tpm_tis 00:0a: 1.2 TPM (device-id 0xFFFF, rev-id 255)
But correct is:
tpm_tis 00:0c: 1.2 TPM (device-id 0x3203, rev-id 9)
This short patch fixes this issue.
Signed-Off-by Marcel Selhorst <tpm@selhorst.net>
---
--- tpm_tis.c.orig 2007-11-19 00:21:09.000000000 +0100
+++ tpm_tis.c 2007-11-19 00:21:23.000000000 +0100
@@ -450,6 +450,11 @@ static int tpm_tis_init(struct device *d
goto out_err;
}
+ if (request_locality(chip, 0) != 0) {
+ rc = -ENODEV;
+ goto out_err;
+ }
+
vendor = ioread32(chip->vendor.iobase + TPM_DID_VID(0));
/* Default timeouts */
@@ -487,11 +492,6 @@ static int tpm_tis_init(struct device *d
if (intfcaps & TPM_INTF_DATA_AVAIL_INT)
dev_dbg(dev, "\tData Avail Int Support\n");
- if (request_locality(chip, 0) != 0) {
- rc = -ENODEV;
- goto out_err;
- }
-
/* INTERRUPT Setup */
init_waitqueue_head(&chip->vendor.read_queue);
init_waitqueue_head(&chip->vendor.int_queue);
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] TPM TIS device driver locality request
2007-11-18 23:32 [PATCH] TPM TIS device driver locality request Marcel Selhorst
@ 2007-11-20 6:23 ` Andrew Morton
2007-11-21 8:29 ` Marcel Selhorst
0 siblings, 1 reply; 3+ messages in thread
From: Andrew Morton @ 2007-11-20 6:23 UTC (permalink / raw)
To: Marcel Selhorst; +Cc: TPM Device Driver List, linux-kernel, Kylene Jo Hall
On Mon, 19 Nov 2007 00:32:51 +0100 Marcel Selhorst <tpm@selhorst.net> wrote:
> Dear all,
>
> during the initialization of the TPM TIS driver, the necessary
> locality has to be requested earlier in the init-process. Depending on
> the used TPM chip, this leads to wrong information.
> For example: Lenovo X61s with Atmel TPM:
>
> tpm_tis 00:0a: 1.2 TPM (device-id 0xFFFF, rev-id 255)
>
> But correct is:
>
> tpm_tis 00:0c: 1.2 TPM (device-id 0x3203, rev-id 9)
>
> This short patch fixes this issue.
Is this bug sufficiently serious to warrant inclusion of the fix in
2.6.24? 2.6.23.x?
It looks like it's just a cosmetic thing, but I'd like to check...
> Signed-Off-by Marcel Selhorst <tpm@selhorst.net>
Signed-off-by:, please.
> ---
> --- tpm_tis.c.orig 2007-11-19 00:21:09.000000000 +0100
> +++ tpm_tis.c 2007-11-19 00:21:23.000000000 +0100
`patch -p1' form, please. This should have been
--- a/drivers/char/tpm/tpm_tis.c
+++ a/drivers/char/tpm/tpm_tis.c
> @@ -450,6 +450,11 @@ static int tpm_tis_init(struct device *d
> goto out_err;
> }
>
> + if (request_locality(chip, 0) != 0) {
> + rc = -ENODEV;
> + goto out_err;
> + }
> +
Your email client is converting tabs to spaces.
http://mbligh.org/linuxdocs/Email/Clients/Thunderbird has help for this.
Thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-11-21 8:32 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-11-18 23:32 [PATCH] TPM TIS device driver locality request Marcel Selhorst
2007-11-20 6:23 ` Andrew Morton
2007-11-21 8:29 ` Marcel Selhorst
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox