[PATCH] tpm: fix gcc printk warnings

From: Randy.Dunlap
Date: Mon Mar 14 2005 - 18:07:03 EST



(Kylene, please add TPM info to MAINTAINERS or CREDITS)

Fix gcc printk arg type warnings:

drivers/char/tpm/tpm.c:145: warning: unsigned int format, different type arg (arg 5)
drivers/char/tpm/tpm.c:153: warning: int format, different type arg (arg 4)
drivers/char/tpm/tpm.c:190: warning: int format, different type arg (arg 4)

Signed-off-by: Randy Dunlap <rddunlap@xxxxxxxx>

diffstat:=
drivers/char/tpm/tpm.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)

diff -Naurp ./drivers/char/tpm/tpm.c~tpm_printk ./drivers/char/tpm/tpm.c
--- ./drivers/char/tpm/tpm.c~tpm_printk 2005-03-14 08:41:24.000000000 -0800
+++ ./drivers/char/tpm/tpm.c 2005-03-14 11:19:28.000000000 -0800
@@ -143,7 +143,7 @@ static ssize_t tpm_transmit(struct tpm_c
return -ENODATA;
if (count > bufsiz) {
dev_err(&chip->pci_dev->dev,
- "invalid count value %x %x \n", count, bufsiz);
+ "invalid count value %x %lx\n", count, (unsigned long)bufsiz);
return -E2BIG;
}

@@ -151,7 +151,7 @@ static ssize_t tpm_transmit(struct tpm_c

if ((len = chip->vendor->send(chip, (u8 *) buf, count)) < 0) {
dev_err(&chip->pci_dev->dev,
- "tpm_transmit: tpm_send: error %d\n", len);
+ "tpm_transmit: tpm_send: error %Zd\n", len);
return len;
}

@@ -188,7 +188,7 @@ out_recv:
len = chip->vendor->recv(chip, (u8 *) buf, bufsiz);
if (len < 0)
dev_err(&chip->pci_dev->dev,
- "tpm_transmit: tpm_recv: error %d\n", len);
+ "tpm_transmit: tpm_recv: error %Zd\n", len);
up(&chip->tpm_mutex);
return len;
}


---
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/