X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs2.git;a=blobdiff_plain;f=yaffs_mtdif.c;h=edc152575302e72a2339e58a730e57e40e028bcc;hp=cdbe42866ebb4fe4227d8533120eb316bb56015f;hb=8e0281ff8c5904d1dbb5b41f3cfadfb05f139437;hpb=976dbeae825b18e6759f3903073a6784248cc244 diff --git a/yaffs_mtdif.c b/yaffs_mtdif.c index cdbe428..edc1525 100644 --- a/yaffs_mtdif.c +++ b/yaffs_mtdif.c @@ -1,7 +1,7 @@ /* * YAFFS: Yet Another Flash File System. A NAND-flash specific file system. * - * Copyright (C) 2002-2010 Aleph One Ltd. + * Copyright (C) 2002-2011 Aleph One Ltd. * for Toby Churchill Ltd and Brightstar Engineering * * Created by Charles Manning @@ -13,7 +13,6 @@ #include "yportenv.h" - #include "yaffs_mtdif.h" #include "linux/mtd/mtd.h" @@ -27,10 +26,9 @@ int nandmtd_erase_block(struct yaffs_dev *dev, int block_no) { struct mtd_info *mtd = yaffs_dev_to_mtd(dev); u32 addr = - ((loff_t) block_no) * dev->param.total_bytes_per_chunk - * dev->param.chunks_per_block; + ((loff_t) block_no) * dev->param.total_bytes_per_chunk * + dev->param.chunks_per_block; struct erase_info ei; - int retval = 0; ei.mtd = mtd; @@ -45,12 +43,11 @@ int nandmtd_erase_block(struct yaffs_dev *dev, int block_no) if (retval == 0) return YAFFS_OK; - else - return YAFFS_FAIL; + + return YAFFS_FAIL; } int nandmtd_initialise(struct yaffs_dev *dev) { return YAFFS_OK; } -