[PATCH 3/4] ARM: i.MX: Add bbu handler for external NAND boot
Sascha Hauer
s.hauer at pengutronix.de
Tue Mar 12 06:05:18 EDT 2013
On Tue, Mar 12, 2013 at 10:48:16AM +0100, Juergen Beisert wrote:
> Sascha Hauer wrote:
> > [...]
> > + if (size_available < 0) {
> > + printf("device is too small\n");
> > + ret = -ENOSPC;
> > + goto out;
> > + }
> > [...]
>
> As the user only sees bad block info when DEBUG is enabled, you should output
> more info here.
> The device (or better partition?) can be too small in general, or it can be
> too small due to many bad blocks inside. IMHO it would be helpful to see more
> info here why it failed.
Ok. I reworded this to:
printf("device is too small.\n"
"raw partition size: 0x%08llx\n"
"partition size w/o bad blocks: 0x%08llx\n"
"size needed: 0x%08x\n",
s.st_size,
s.st_size - num_bb * blocksize,
data->len);
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
More information about the barebox
mailing list