[PATCH v3 25/37] mtd: nand: denali: switch over to cmd_ctrl instead of cmdfunc

Boris Brezillon boris.brezillon at free-electrons.com
Thu Mar 30 08:55:44 PDT 2017


On Thu, 30 Mar 2017 15:46:11 +0900
Masahiro Yamada <yamada.masahiro at socionext.com> wrote:


>  /*
>   * sends a pipeline command operation to the controller. See the Denali NAND
>   * controller's user guide for more information (section 4.2.3.6).
> @@ -824,7 +856,13 @@ static void denali_select_chip(struct mtd_info *mtd, int chip)
>  
>  static int denali_waitfunc(struct mtd_info *mtd, struct nand_chip *chip)
>  {
> -	return 0;
> +	struct denali_nand_info *denali = mtd_to_denali(mtd);
> +	uint32_t irq_status;
> +
> +	/* R/B# pin transitioned from low to high? */
> +	irq_status = denali_wait_for_irq(denali, INTR__INT_ACT);
> +
> +	return irq_status & INTR__INT_ACT ? 0 : NAND_STATUS_FAIL;

Okay, you fix the ->waitfunc() implementation here. Great! Then I'm
fine with patch 18.

>  }



More information about the linux-mtd mailing list