summaryrefslogtreecommitdiffstats
path: root/drivers/mtd/mtdswap.c
diff options
context:
space:
mode:
authorDavid Woodhouse <David.Woodhouse@intel.com>2011-03-11 15:17:41 +0000
committerDavid Woodhouse <David.Woodhouse@intel.com>2011-03-11 15:17:41 +0000
commit89d8d32060de17c23f761df74799c7c07b79dd01 (patch)
tree408f3e584c8dc3548a2eda75b106dc72317d01f7 /drivers/mtd/mtdswap.c
parent629286b9561982e90a6d49893a1c641e71b6a2a3 (diff)
downloadblackbird-op-linux-89d8d32060de17c23f761df74799c7c07b79dd01.tar.gz
blackbird-op-linux-89d8d32060de17c23f761df74799c7c07b79dd01.zip
mtd: fix printf format warnings, mostly lack of %zd for size_t, in mtdswap
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Diffstat (limited to 'drivers/mtd/mtdswap.c')
-rw-r--r--drivers/mtd/mtdswap.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/mtd/mtdswap.c b/drivers/mtd/mtdswap.c
index 57e6cc30bc42..a65594fee4a3 100644
--- a/drivers/mtd/mtdswap.c
+++ b/drivers/mtd/mtdswap.c
@@ -331,7 +331,7 @@ static int mtdswap_read_oob(struct mtdswap_dev *d, loff_t from,
if (ops->oobretlen < ops->ooblen) {
dev_warn(d->dev, "Read OOB return short read (%zd bytes not "
- "%d) for block at %08llx\n",
+ "%zd) for block at %08llx\n",
ops->oobretlen, ops->ooblen, from);
return -EIO;
}
@@ -421,7 +421,7 @@ static int mtdswap_write_marker(struct mtdswap_dev *d, struct swap_eb *eb,
if (ops.oobretlen != ops.ooblen) {
dev_warn(d->dev, "Short OOB write for block at %08llx: "
- "%zd not %d\n",
+ "%zd not %zd\n",
offset, ops.oobretlen, ops.ooblen);
return ret;
}
@@ -705,13 +705,13 @@ retry:
}
if (ret < 0) {
- dev_err(d->dev, "Write to MTD device failed: %d (%d written)",
+ dev_err(d->dev, "Write to MTD device failed: %d (%zd written)",
ret, retlen);
goto err;
}
if (retlen != PAGE_SIZE) {
- dev_err(d->dev, "Short write to MTD device: %d written",
+ dev_err(d->dev, "Short write to MTD device: %zd written",
retlen);
ret = -EIO;
goto err;
@@ -758,7 +758,7 @@ retry:
}
if (retlen != PAGE_SIZE) {
- dev_err(d->dev, "Short read: %d (block %u)\n", retlen,
+ dev_err(d->dev, "Short read: %zd (block %u)\n", retlen,
oldblock);
ret = -EIO;
goto read_error;
@@ -1188,7 +1188,7 @@ retry:
}
if (retlen != PAGE_SIZE) {
- dev_err(d->dev, "Short read %d\n", retlen);
+ dev_err(d->dev, "Short read %zd\n", retlen);
return -EIO;
}
@@ -1304,7 +1304,7 @@ static int mtdswap_show(struct seq_file *s, void *data)
seq_printf(s, "discarded pages count: %llu\n", d->discard_page_count);
seq_printf(s, "\n");
- seq_printf(s, "total pages: %lu\n", pages);
+ seq_printf(s, "total pages: %u\n", pages);
seq_printf(s, "pages mapped: %u\n", mapped);
return 0;
@@ -1458,7 +1458,7 @@ static void mtdswap_add_mtd(struct mtd_blktrans_ops *tr, struct mtd_info *mtd)
oinfo = mtd->ecclayout;
if (!mtd->oobsize || !oinfo || oinfo->oobavail < MTDSWAP_OOBSIZE) {
printk(KERN_ERR "%s: Not enough free bytes in OOB, "
- "%d available, %u needed.\n",
+ "%d available, %lu needed.\n",
MTDSWAP_PREFIX, oinfo->oobavail, MTDSWAP_OOBSIZE);
return;
}
OpenPOWER on IntegriCloud