nvmem: ocotp: Change TIMING calculation algorithm
Port of patch from linux-arm-kernel:
| From: Bryan O'Donoghue <pure.logic@nexus-software.ie>
|
| nvmem: imx-ocotp: Change TIMING calculation to u-boot algorithm
|
| The RELAX field of the OCOTP block is turning out as a zero on i.MX8MM.
| This messes up the subsequent re-load of the fuse shadow registers.
|
| After some discussion with people @ NXP its clear we have missed a trick
| here in Linux.
|
| The OCOTP fuse programming time has a physical minimum 'burn time' that is
| not related to the ipg_clk.
|
| We need to define the RELAX, STROBE_READ and STROBE_PROG fields in terms of
| desired timings to allow for the burn-in to safely complete. Right now only
| the RELAX field is calculated in terms of an absolute time and we are
| ending up with a value of zero.
|
| This patch inherits the u-boot timings for the OCOTP_TIMING calculation on
| the i.MX6 and i.MX8. Those timings are known to work and critically specify
| values such as STROBE_PROG as a minimum timing.

Signed-off-by: Rouven Czerwinski <r.czerwinski@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
1 parent 18ac9eb commit b7c0ec207ef11ce756e169e8507d97a57305dc87
@Rouven Czerwinski Rouven Czerwinski authored on 11 Jun 2019
Sascha Hauer committed on 11 Jun 2019
Showing 1 changed file
View
drivers/nvmem/ocotp.c