lkml.org 
[lkml]   [2023]   [Feb]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Subject[PATCH v3 0/4] watchdog: mt7621-wdt: avoid globals and arch dependencies
Date
Hi all,

This series make an update in the MT7621 SoC's watchdog driver code. This
SoC already provides a system controller node to access reset status
register needed for the watchdog. Instead of using MIPS architecture
dependent operations in header 'asm/mach-ralink/ralink_regs.h' use
a phandle to the system controller node and use it through regmap APIs
from the code. Driver is also using some globals that are not needed at
all if a driver data structure is used along the code. Hence, add all
new needed stuff inside a new driver data structure. With this changes
driver can be properly compile tested.

Thanks in advance for reviewing this!

V1 of this series here [0].
V2 os thise series here [1].

Changes in v3:
- rename phandler from 'ralink,sysctl' into 'mediatek,sysctl'.
- Drop error message added in PATHC 3 that modifies functionality and we
only want to maintain current functionaloty by now.

Changes in v2:
- Remove no needed compatible 'syscon' from bindings.
- Rewrite new syscon phandle description in bindings.
- Remove 'syscon' from compatible in 'mt7621.dtsi'.
- Split PATCH 3 into two different patches:
- PATCH 3: removes static globals using a driver data structure.
- PATCH 4: remove ralink architecture dependent includes and code.

Best regards,
Sergio Paracuellos

[0]: https://lore.kernel.org/linux-watchdog/20230210065621.598120-1-sergio.paracuellos@gmail.com/T/#t
[1]: https://lore.kernel.org/linux-watchdog/20230210121735.639089-1-sergio.paracuellos@gmail.com/T/#t

Sergio Paracuellos (4):
dt-bindings: watchdog: mt7621-wdt: add phandle to access system
controller registers
mips: dts: ralink: mt7621: add phandle to system controller node for
watchdog
watchdog: mt7621-wdt: avoid static global declarations
watchdog: mt7621-wdt: avoid ralink architecture dependent code

.../watchdog/mediatek,mt7621-wdt.yaml | 7 ++
arch/mips/boot/dts/ralink/mt7621.dtsi | 1 +
drivers/watchdog/Kconfig | 2 +
drivers/watchdog/mt7621_wdt.c | 119 ++++++++++++------
4 files changed, 88 insertions(+), 41 deletions(-)

--
2.25.1

\
 
 \ /
  Last update: 2023-03-27 00:18    [W:0.055 / U:0.128 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site