nand_util: convert nand_write_skip_bad() to flags
authorBen Gardiner <bengardiner@nanometrics.ca>
Tue, 24 May 2011 14:18:35 +0000 (10:18 -0400)
committerScott Wood <scottwood@freescale.com>
Fri, 1 Jul 2011 20:56:51 +0000 (15:56 -0500)
commita6c9aa1f92dd16a0ec6faeff37069db61d3f7cf3
tree9328511116f7ad2e2525d8d1a5c24d92f1ebd654
parentbee038e9fe2fe0fcd53e89aac32fb8948555c040
nand_util: convert nand_write_skip_bad() to flags

In a future commit the behaviour of nand_write_skip_bad()
will be further extended.

Convert the only flag currently passed to the nand_write_
skip_bad() function to a bitfield of only one allocated
member. This should avoid an explosion of int's at the
end of the parameter list or the ambiguous calls like

nand_write_skip_bad(info, offset, len, buf, 0, 1, 1);
nand_write_skip_bad(info, offset, len, buf, 0, 1, 0);

Instead there will be:

nand_write_skip_bad(info, offset, len, buf, WITH_YAFFS_OOB |
WITH_OTHER);

Signed-off-by: Ben Gardiner <bengardiner@nanometrics.ca>
Acked-by: Detlev Zundel <dzu@denx.de>
Signed-off-by: Scott Wood <scottwood@freescale.com>
common/cmd_nand.c
drivers/mtd/nand/nand_util.c
include/nand.h