modify nand flash code error and make nand read and write successful