mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* 3 warnings from drivers/acpi/processor_idle.c
@ 2004-12-29 23:57 Luck, Tony
  0 siblings, 0 replies; only message in thread
From: Luck, Tony @ 2004-12-29 23:57 UTC (permalink / raw)
  To: len.brown; +Cc: linux-kernel

Compiling on ia64 I see:
drivers/acpi/processor_idle.c:846: warning: int format, different type arg (arg 3)
drivers/acpi/processor_idle.c:877: warning: int format, different type arg (arg 3)
drivers/acpi/processor_idle.c:884: warning: int format, different type arg (arg 3)

This is the result of using "%d" to print the difference between two pointers.

Use "%zd" instead.

Signed-off-by: Tony Luck <tony.luck@intel.com>

===== drivers/acpi/processor_idle.c 1.15 vs edited =====
--- 1.15/drivers/acpi/processor_idle.c	2004-12-23 05:39:58 -08:00
+++ edited/drivers/acpi/processor_idle.c	2004-12-29 15:45:49 -08:00
@@ -838,7 +838,7 @@
 	if (!pr)
 		goto end;
 
-	seq_printf(seq, "active state:            C%d\n"
+	seq_printf(seq, "active state:            C%zd\n"
 			"max_cstate:              C%d\n"
 			"bus master activity:     %08x\n",
 			pr->power.state ? pr->power.state - pr->power.states : 0,
@@ -872,14 +872,14 @@
 		}
 
 		if (pr->power.states[i].promotion.state)
-			seq_printf(seq, "promotion[C%d] ",
+			seq_printf(seq, "promotion[C%zd] ",
 				(pr->power.states[i].promotion.state -
 				 pr->power.states));
 		else
 			seq_puts(seq, "promotion[--] ");
 
 		if (pr->power.states[i].demotion.state)
-			seq_printf(seq, "demotion[C%d] ",
+			seq_printf(seq, "demotion[C%zd] ",
 				(pr->power.states[i].demotion.state -
 				 pr->power.states));
 		else

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2004-12-29 23:57 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-12-29 23:57 3 warnings from drivers/acpi/processor_idle.c Luck, Tony

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

all inboxes | Powered by JetHome®