[PATCH 1/1] mx7ulp: Update wdog disable sequence

sbabic at denx.de sbabic at denx.de
Thu Oct 7 16:13:49 CEST 2021

> From: Ye Li <ye.li at nxp.com>
> Update the mx7ulp wdog disable sequence to avoid potential reset
> issue in unlock or refresh sequence. Both sequence need two words
> write to wdog CNT register in 16 bus clocks window, if miss the
> window, the write will cause violation in wdog and reset the chip.
> Current u-boot code is using writel() function which has a DMB
> barrier to order the memory access. The DMB between two words write
> may introduce some delay in certain circumstance, causing the wdog
> reset due to 16 bus clock window requirement.
> Also, WDOG1 might have been enabled already depending on FUSE hence
> we need to be as close as possible to its reconfiguration timing
> requirement of 128 bus clock limit.
> This patch replaces writel() function by __raw_writel() to avoid such
> issue, and improve to check if watchdog is already disabled or
> unlocked.
> Signed-off-by: Ye Li <ye.li at nxp.com>
> Co-developed-by: Jorge Ramirez-Ortiz <jorge at foundries.io>
> Signed-off-by: Jorge Ramirez-Ortiz <jorge at foundries.io>
> Co-developed-by: Ricardo Salveti <ricardo at foundries.io>
> Signed-off-by: Ricardo Salveti <ricardo at foundries.io>
> Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov at foundries.io>
Applied to u-boot-imx, master, thanks !

Best regards,
Stefano Babic

DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de

More information about the U-Boot mailing list