Go to the documentation of this file.00001 #ifndef __FTLSIMPLE_H__
00002 #define __FTLSIMPLE_H__
00003
00004 #include "types.h"
00005
00006 #define PAGE_MASK ((1<<(config_nand.bit_page_per_blk))-1)
00007 #define BLK_F_PA(pa) ((pa)>>(config_nand.bit_page_per_blk))
00008 #define PN_F_PA(pa) ((pa) & PAGE_MASK)
00009 #define MAKE_PA(blk, pn) (((blk)<<(config_nand.bit_page_per_blk)) + (pn))
00010
00011 int ftl_open();
00012 void ftl_close();
00013
00014 _t_size ftl_read(_t_sect lsn, _t_size size);
00015 _t_size ftl_write(_t_sect lsn, _t_size size);
00016
00017 #endif // __FTLSIMPLE_H__