Patchwork [03/12] mtd: nandsim: don't call nand_default_bbt() directly

login
register
mail settings
Submitter Brian Norris
Date Sept. 4, 2013, 6:25 p.m.
Message ID <1378319126-24473-4-git-send-email-computersforpeace@gmail.com>
Download mbox | patch
Permalink /patch/272702/
State Accepted
Commit 4fd18ae46d207987737d94f8d67483f8d8813b15
Headers show

Comments

Brian Norris - Sept. 4, 2013, 6:25 p.m.
We want the default nand_chip.scan_bbt() function, so just use the
proper indirection.

Signed-off-by: Brian Norris <computersforpeace@gmail.com>
---
 drivers/mtd/nand/nandsim.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch

diff --git a/drivers/mtd/nand/nandsim.c b/drivers/mtd/nand/nandsim.c
index bdc1d15..fdcc5bd 100644
--- a/drivers/mtd/nand/nandsim.c
+++ b/drivers/mtd/nand/nandsim.c
@@ -2372,7 +2372,7 @@  static int __init ns_init_module(void)
 	if ((retval = init_nandsim(nsmtd)) != 0)
 		goto err_exit;
 
-	if ((retval = nand_default_bbt(nsmtd)) != 0)
+	if ((retval = chip->scan_bbt(nsmtd)) != 0)
 		goto err_exit;
 
 	if ((retval = parse_badblocks(nand, nsmtd)) != 0)