summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiguel Figueiredo <elmig@debianpt.org>2013-06-04 19:54:29 +0200
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2013-06-04 19:54:29 +0200
commit21fff41626efc52861648edfe00c6ceecaa3a59c (patch)
tree946944e8f31accb6027cc25919070117b3b0b2c7
parente124fdce292d027b6b57cd10be41c37624313a90 (diff)
Fix format warnings
* vm/vm_resident.c (pmap_startup): Fix printf format. * xen/block.c (hyp_block_init, device_write): Likewise. * xen/net.c (hyp_net_init): Likewise.
-rw-r--r--vm/vm_resident.c2
-rw-r--r--xen/block.c8
-rw-r--r--xen/net.c4
3 files changed, 7 insertions, 7 deletions
diff --git a/vm/vm_resident.c b/vm/vm_resident.c
index 7cf4fb1..d2edf5a 100644
--- a/vm/vm_resident.c
+++ b/vm/vm_resident.c
@@ -395,7 +395,7 @@ void pmap_startup(
while (pmap_next_page(&paddr))
i++;
if (i)
- printf("%d memory page(s) left away\n", i);
+ printf("%u memory page(s) left away\n", i);
/*
* Release pages in reverse order so that physical pages
diff --git a/xen/block.c b/xen/block.c
index 4253ef0..3e4ce7c 100644
--- a/xen/block.c
+++ b/xen/block.c
@@ -214,9 +214,9 @@ void hyp_block_init(void) {
continue;
}
if (partition)
- sprintf(device_name, "%s%us%u", prefix, disk, partition);
+ sprintf(device_name, "%s%ds%d", prefix, disk, partition);
else
- sprintf(device_name, "%s%u", prefix, disk);
+ sprintf(device_name, "%s%d", prefix, disk);
bd->name = (char*) kalloc(strlen(device_name));
strcpy(bd->name, device_name);
@@ -238,7 +238,7 @@ void hyp_block_init(void) {
grant = hyp_grant_give(domid, atop(addr), 0);
/* and give it to backend. */
- i = sprintf(port_name, "%u", grant);
+ i = sprintf(port_name, "%d", grant);
c = hyp_store_write(t, port_name, 5, VBD_PATH, "/", vbds[n], "/", "ring-ref");
if (!c)
panic("%s: couldn't store ring reference (%s)", device_name, hyp_store_error);
@@ -670,7 +670,7 @@ device_write(void *d, ipc_port_t reply_port,
hyp_grant_takeback(gref[j]);
if (err) {
- printf("error writing %d bytes at sector %d\n", count, bn);
+ printf("error writing %u bytes at sector %d\n", count, bn);
break;
}
}
diff --git a/xen/net.c b/xen/net.c
index 10e4bbe..fb26471 100644
--- a/xen/net.c
+++ b/xen/net.c
@@ -366,7 +366,7 @@ void hyp_net_init(void) {
grant = hyp_grant_give(domid, atop(addr), 0);
/* and give it to backend. */
- i = sprintf(port_name, "%u", grant);
+ i = sprintf(port_name, "%d", grant);
c = hyp_store_write(t, port_name, 5, VIF_PATH, "/", vifs[n], "/", "tx-ring-ref");
if (!c)
panic("eth: couldn't store tx_ring reference for VIF %s (%s)", vifs[n], hyp_store_error);
@@ -381,7 +381,7 @@ void hyp_net_init(void) {
grant = hyp_grant_give(domid, atop(addr), 0);
/* and give it to backend. */
- i = sprintf(port_name, "%u", grant);
+ i = sprintf(port_name, "%d", grant);
c = hyp_store_write(t, port_name, 5, VIF_PATH, "/", vifs[n], "/", "rx-ring-ref");
if (!c)
panic("eth: couldn't store rx_ring reference for VIF %s (%s)", vifs[n], hyp_store_error);