[U-Boot] [PATCH v6 2/4] mtd, nand: move common functions from cmd_nand.c to common place