Re: [PATCH v4 2/2] mtd: mediatek: driver for MTK Smart Device Gen1 NAND

Jorge Ramirez
2016-05-10T14:53:50Z

On 05/10/2016 08:13 AM, Boris Brezillon wrote:
>> +
>> >+void mtk_ecc_disable(struct mtk_ecc *ecc, struct mtk_ecc_config *config)
> If you save the mode somewhere in mtk_ecc (or just write in both ENC
> and DEC registers), you won't need this extra config arg here.

ok.

>
>> >+{
>> >+ enum mtk_ecc_codec codec = config->codec;
>> >+
>> >+ mtk_ecc_codec_wait_idle(ecc, codec);
>> >+ writew(0, ecc->regs + ECC_IRQ_REG(codec));
>> >+ writew(ECC_CODEC_DISABLE(codec), ecc->regs + ECC_CTL_REG(codec));
>> >+ up(&ecc->sem);
>> >+}
>> >+EXPORT_SYMBOL(mtk_ecc_disable);