[MTD] fix nftl_write warning
Linux-MTD Mailing List
linux-mtd at lists.infradead.org
Mon Oct 2 04:59:01 EDT 2006
Commit: 553a8012088b3452c7d66ff60d2d06ad0c9bea00
Parent: 9a292308255ad381dd74541be468c4aec240a615
commit 553a8012088b3452c7d66ff60d2d06ad0c9bea00
Author: Frederik Deweerdt <deweerdt at free.fr>
AuthorDate: Mon Oct 2 09:42:25 2006 +0100
Commit: David Woodhouse <dwmw2 at infradead.org>
CommitDate: Mon Oct 2 09:42:25 2006 +0100
[MTD] fix nftl_write warning
Building 2.6.18-mm2 issues the following warning if CONFIG_NFTL_RW is not set:
CC [M] drivers/mtd/nftlcore.o
drivers/mtd/nftlcore.c:183: warning: 'nftl_write' defined but not used
The following patch only compiles nftl_write if CONFIG_NFTL_RW is set.
Signed-off-by: Frederik Deweerdt <frederik.deweerdt at gmail.com>
Signed-off-by: Andrew Morton <akpm at osdl.org>
Signed-off-by: David Woodhouse <dwmw2 at infradead.org>
---
drivers/mtd/nftlcore.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/mtd/nftlcore.c b/drivers/mtd/nftlcore.c
index dd5cea8..b5a5f8d 100644
--- a/drivers/mtd/nftlcore.c
+++ b/drivers/mtd/nftlcore.c
@@ -175,6 +175,8 @@ int nftl_write_oob(struct mtd_info *mtd,
return res;
}
+#ifdef CONFIG_NFTL_RW
+
/*
* Write data and oob to flash
*/
@@ -196,8 +198,6 @@ static int nftl_write(struct mtd_info *m
return res;
}
-#ifdef CONFIG_NFTL_RW
-
/* Actual NFTL access routines */
/* NFTL_findfreeblock: Find a free Erase Unit on the NFTL partition. This function is used
* when the give Virtual Unit Chain
More information about the linux-mtd-cvs
mailing list