Skip to content

watchdog: mtk_wdt: refactor code to support more watchdogs

Boris Lysov linux-devicetree linux-mediatek 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest3 patches 4 repliesIn review
  2. v23 patches 3 repliesSuperseded

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3watchdog: mtk_wdt: Refactor code to support more SoCsdrivers/watchdog/mtk_wdt.c+52 -141 reply
2/3dt-bindings: watchdog: mediatek: add support for mt6577 SoCDocumentation/devicetree/bindings/watchdog/mtk-wdt.txt+1 -02 replies
3/3watchdog: mtk_wdt: add support for mt6577drivers/watchdog/mtk_wdt.c+12 -01 reply

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchRob HerringGuenter Roeck
1/3R-b
2/3A-b R-b
3/3R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH v3 0/3] watchdog: mtk_wdt: refactor code to support more watchdogs

This series aims to refactor existing mtk_wdt driver by making some constants dependent on a particular SoC. It is done because some mtk watchdogs, while working in same manner, have slightly different parameters such as specific register unlock key value and an offset of a particular register field.

This patch set adds support for mt6577 watchdog.

Accepting these patches will make ground for submitting additional changes related to the mainline support of mt6577 (and other compatible SoCs) in future.

Proposed patches successfully pass all checkpatch.pl checks and don't yield compiler warnings.

Resulting code has been thoroughly tested multiple times for hours on real hardware (mt6577, mt6589) to ensure that proposed changes are working properly.

Changes since v2 [3]:
- rename the newly introduced structure element ('data' -> 'config') to avoid changing the names of already existing variables; suggested [4] by Guenter Roeck.

Changes since v1 [1]:
- a complete rewrite to get rid of the configuration flags which made the watchdog not support other SoCs; suggested [2] by Guenter Roeck.

[1] https://lore.kernel.org/linux-mediatek/[email protected]/
[2] https://lore.kernel.org/linux-mediatek/[email protected]/
[3] https://lore.kernel.org/linux-mediatek/[email protected]/
[4] https://lore.kernel.org/linux-mediatek/[email protected]/

Boris Lysov (3):
watchdog: mtk_wdt: Refactor code to support more SoCs
dt-bindings: watchdog: mediatek: add support for mt6577 SoC
watchdog: mtk_wdt: add support for mt6577

 .../devicetree/bindings/watchdog/mtk-wdt.txt  |  1 +
 drivers/watchdog/mtk_wdt.c                    | 88 +++++++++++++++----
 2 files changed, 70 insertions(+), 19 deletions(-)
Signature · 1 line
2.20.1