public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] tpm: fix gcc printk warnings
@ 2005-03-14 22:55 Randy.Dunlap
  2005-03-14 23:08 ` Andrew Morton
  2005-04-27 22:18 ` [PATCH 8 of 12] Fix Tpm driver -- Maintainers entry Kylene Hall
  0 siblings, 2 replies; 5+ messages in thread
From: Randy.Dunlap @ 2005-03-14 22:55 UTC (permalink / raw)
  To: kjhall, akpm; +Cc: lkml


(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@osdl.org>

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;
 }


---

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] tpm: fix gcc printk warnings
  2005-03-14 22:55 [PATCH] tpm: fix gcc printk warnings Randy.Dunlap
@ 2005-03-14 23:08 ` Andrew Morton
  2005-03-14 23:16   ` Randy.Dunlap
  2005-04-27 22:18 ` [PATCH 8 of 12] Fix Tpm driver -- Maintainers entry Kylene Hall
  1 sibling, 1 reply; 5+ messages in thread
From: Andrew Morton @ 2005-03-14 23:08 UTC (permalink / raw)
  To: Randy.Dunlap; +Cc: kjhall, linux-kernel

"Randy.Dunlap" <rddunlap@osdl.org> wrote:
>
> -			"invalid count value %x %x \n", count, bufsiz);
> +			"invalid count value %x %lx\n", count, (unsigned long)bufsiz);

Nope.  Please use %Z for size_t args.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] tpm: fix gcc printk warnings
  2005-03-14 23:08 ` Andrew Morton
@ 2005-03-14 23:16   ` Randy.Dunlap
  2005-04-15 21:09     ` Kylene Jo Hall
  0 siblings, 1 reply; 5+ messages in thread
From: Randy.Dunlap @ 2005-03-14 23:16 UTC (permalink / raw)
  To: Andrew Morton; +Cc: kjhall, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 140 bytes --]

Andrew Morton wrote:
> "Randy.Dunlap" <rddunlap@osdl.org> wrote:
> 
> Nope.  Please use %Z for size_t args.

Yeps.  Here it is.

-- 
~Randy

[-- Attachment #2: tpm_printk_v2.patch --]
[-- Type: text/x-patch, Size: 1450 bytes --]



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@osdl.org>

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 15:11:23.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 %Zx\n", count, 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;
 }

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] tpm: fix gcc printk warnings
  2005-03-14 23:16   ` Randy.Dunlap
@ 2005-04-15 21:09     ` Kylene Jo Hall
  0 siblings, 0 replies; 5+ messages in thread
From: Kylene Jo Hall @ 2005-04-15 21:09 UTC (permalink / raw)
  To: Randy.Dunlap; +Cc: Andrew Morton, linux-kernel

The patch that was attached to this orginal message looks good to me and
can be applied to the Tpm driver.

Thanks,
Kylie

On Mon, 2005-03-14 at 15:16 -0800, Randy.Dunlap wrote:
> Andrew Morton wrote:
> > "Randy.Dunlap" <rddunlap@osdl.org> wrote:
> > 
> > Nope.  Please use %Z for size_t args.
> 
> Yeps.  Here it is.
> 


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH 8 of 12] Fix Tpm driver -- Maintainers entry
  2005-03-14 22:55 [PATCH] tpm: fix gcc printk warnings Randy.Dunlap
  2005-03-14 23:08 ` Andrew Morton
@ 2005-04-27 22:18 ` Kylene Hall
  1 sibling, 0 replies; 5+ messages in thread
From: Kylene Hall @ 2005-04-27 22:18 UTC (permalink / raw)
  To: Randy.Dunlap; +Cc: akpm, lkml

On Mon, 14 Mar 2005, Randy.Dunlap wrote:
> (Kylene, please add TPM info to MAINTAINERS or CREDITS)

This patch adds the maintainers entry.

Signed-off-by: Kylene Hall <kjhall@us.ibm.com
---
--- linux-2.6.12-rc2/MAINTAINERS	2005-04-04 11:38:36.000000000 -0500
+++ linux-2.6.12-rc2-tpmdd/MAINTAINERS	2005-04-14 14:45:57.000000000 -0500
@@ -2116,6 +2116,13 @@ M:	perex@suse.cz
 L:	alsa-devel@alsa-project.org
 S:	Maintained
 
+TPM DEVICE DRIVER
+P:	Kylene Hall
+M:	kjhall@us.ibm.com
+W:	http://tpmdd.sourceforge.net
+L:	tpmdd-devel@lists.sourceforge.net
+S:	Maintained
+
 UltraSPARC (sparc64):
 P:	David S. Miller
 M:	davem@davemloft.net

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2005-04-27 22:22 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-03-14 22:55 [PATCH] tpm: fix gcc printk warnings Randy.Dunlap
2005-03-14 23:08 ` Andrew Morton
2005-03-14 23:16   ` Randy.Dunlap
2005-04-15 21:09     ` Kylene Jo Hall
2005-04-27 22:18 ` [PATCH 8 of 12] Fix Tpm driver -- Maintainers entry Kylene Hall

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox