Optimizing a Flash Media Manager for NAND Flash Imaging