]> git.baikalelectronics.ru Git - kernel.git/commit
mtd: nandsim: convert pages_written[] to bitmap
authorAkinobu Mita <akinobu.mita@gmail.com>
Sun, 28 Jul 2013 02:21:53 +0000 (11:21 +0900)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Mon, 5 Aug 2013 20:05:21 +0000 (21:05 +0100)
commit641ed98e285d5abf438aea8543be4bdd2bc6f3ee
tree7e6ca93afeb8b14475461ebd1d9795258b51042e
parentaffb76dc291209872a4265ab063ae52051294dc1
mtd: nandsim: convert pages_written[] to bitmap

nandsim.pages_written[] is the array of unsigned char which is indexed
by the page number and used for identifying which pages have been written
when cache_file is used.  Each entry holds 0 (not written) or 1 (written),
so it can be converted to bitmap.  This reduces the allocation size of
pages_written[] by 1/8.

Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
drivers/mtd/nand/nandsim.c