Commit d7048666 authored by Esben Haabendal's avatar Esben Haabendal Committed by Miquel Raynal

mtd: rawnand: gpmi: Restore nfc timing setup after suspend/resume

As we reset the GPMI block at resume, the timing parameters setup by a
previous exec_op is lost.  Rewriting GPMI timing registers on first exec_op
after resume fixes the problem.

Fixes: ef347c0c ("mtd: rawnand: gpmi: Implement exec_op")
Cc: stable@vger.kernel.org
Signed-off-by: default avatarEsben Haabendal <esben@geanix.com>
Acked-by: default avatarHan Xu <han.xu@nxp.com>
Signed-off-by: default avatarMiquel Raynal <miquel.raynal@bootlin.com>
parent 5bc6bb60
...@@ -2727,6 +2727,10 @@ static int gpmi_pm_resume(struct device *dev) ...@@ -2727,6 +2727,10 @@ static int gpmi_pm_resume(struct device *dev)
return ret; return ret;
} }
/* Set flag to get timing setup restored for next exec_op */
if (this->hw.clk_rate)
this->hw.must_apply_timings = true;
/* re-init the BCH registers */ /* re-init the BCH registers */
ret = bch_set_geometry(this); ret = bch_set_geometry(this);
if (ret) { if (ret) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment