/* omap_nand_hwcontrol - Set the address pointers corretly for the following address/data/command operation  */
static void omap_nand_hwcontrol(struct mtd_info *mtd, int32_t cmd, uint32_t ctrl)
/* omap_nand_hwcontrol - Set the address pointers corretly for the following address/data/command operation  */
static void omap_nand_hwcontrol(struct mtd_info *mtd, int32_t cmd, uint32_t ctrl)
{
	register struct nand_chip *this = mtd_to_nand(mtd);
	struct omap_nand_info *info = nand_get_controller_data(this);
	int cs = info->cs;
	switch (ctrl) {
	case NAND_CTRL_CHANGE | NAND_CTRL_CLE:
		this->IO_ADDR_W = (void __iomem *)&gpmc_cfg->cs[cs].nand_cmd;
		break;
	case NAND_CTRL_CHANGE | NAND_CTRL_ALE:
		this->IO_ADDR_W = (void __iomem *)&gpmc_cfg->cs[cs].nand_adr;
		break;
	case NAND_CTRL_CHANGE | NAND_NCE:
		this->IO_ADDR_W = (void __iomem *)&gpmc_cfg->cs[cs].nand_dat;
		break;
	}
	if (cmd != NAND_CMD_NONE)
		writeb(cmd, this->IO_ADDR_W);
}