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;
}
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;
}
}
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;
}
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;
}
if (retlen != PAGE_SIZE) {
- dev_err(d->dev, "Short read %d\n", retlen);
+ dev_err(d->dev, "Short read %zd\n", retlen);
return -EIO;
}
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;
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;
}