[PATCH 10/10] mtd: nand: Add command to generate a flash BBT
Sascha Hauer
s.hauer at pengutronix.de
Tue Mar 5 05:49:02 EST 2013
On Mon, Mar 04, 2013 at 09:43:11PM +0100, Juergen Beisert wrote:
> Sascha Hauer wrote:
> > [...]
> > +static int do_imx_nand_bbm(int argc, char *argv[])
> > +{
> > + int opt, ret;
> > + struct cdev *cdev;
> > + struct mtd_info *mtd;
> > + int yes = 0;
> > + void *bbt;
> > +
> > + while ((opt = getopt(argc, argv, "y")) > 0) {
> > + switch (opt) {
> > + case 'y':
> > + yes = 1;
> > + break;
> > + default:
> > + return COMMAND_ERROR_USAGE;
> > + }
> > + }
> > +
> > + cdev = cdev_open("nand0", O_RDWR);
>
> Is a fixed name a good idea?
Since there is only one NAND device on i.MX I think it's ok.
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