mbox series

[edk2,v2,0/4] ArmPkg, ArmPlatformPkg: watchdog driver cleanup

Message ID 20181219204023.6317-1-ard.biesheuvel@linaro.org
Headers show
Series ArmPkg, ArmPlatformPkg: watchdog driver cleanup | expand

Message

Ard Biesheuvel Dec. 19, 2018, 8:40 p.m. UTC
This series cleans up the code of the two watchdog drivers we have for
ARM systems, and brings them in compliance with the PI spec, which
specifies that the default action of the watchdog can be overridden
by registering a handler.

Note that the TC2 code in edk2-platforms will have to be brought up to
date. The SP805 on the FVP model seems terminally broken (it is 'wired'
to the 24 MHz APB clock instead of the 32 kHz WDOG clock, so I'll switch
that one over to use the SBSA watchdog instead)

Changes since v1:
- always fall back to calling gRT_>ResetSystem() if the registered handler
  returns
- WARN() if running the SP805 driver with interrupt handling disabled
- add some R-bs

Cc: Leif Lindholm <leif.lindholm@linaro.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Thomas Panakamattam Abraham <thomas.abraham@arm.com>
Cc: Meenakshi Aggarwal <meenakshi.aggarwal@nxp.com>
Cc: Udit Kumar <udit.kumar@nxp.com>
Cc: Matteo Carlini <Matteo.Carlini@arm.com>
Cc: Nariman Poushin <nariman.poushin@linaro.org>

Ard Biesheuvel (4):
  ArmPlatformPkg/SP805WatchdogDxe: cosmetic cleanup
  ArmPlatformPkg/SP805WatchdogDxe: switch to interrupt mode
  ArmPkg/GenericWatchdogDxe: clean up the code
  ArmPkg/GenericWatchdogDxe: implement RegisterHandler() method

 ArmPlatformPkg/ArmPlatformPkg.dec             |   1 +
 .../GenericWatchdogDxe/GenericWatchdogDxe.inf |   9 +-
 .../SP805WatchdogDxe/SP805WatchdogDxe.inf     |  15 +-
 .../GenericWatchdogDxe/GenericWatchdogDxe.c   | 143 ++++++++------
 .../Drivers/SP805WatchdogDxe/SP805Watchdog.c  | 187 +++++++++++-------
 5 files changed, 213 insertions(+), 142 deletions(-)

-- 
2.19.2

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel

Comments

Ard Biesheuvel Dec. 20, 2018, 11:42 a.m. UTC | #1
On Wed, 19 Dec 2018 at 21:40, Ard Biesheuvel <ard.biesheuvel@linaro.org> wrote:
>

> This series cleans up the code of the two watchdog drivers we have for

> ARM systems, and brings them in compliance with the PI spec, which

> specifies that the default action of the watchdog can be overridden

> by registering a handler.

>

> Note that the TC2 code in edk2-platforms will have to be brought up to

> date. The SP805 on the FVP model seems terminally broken (it is 'wired'

> to the 24 MHz APB clock instead of the 32 kHz WDOG clock, so I'll switch

> that one over to use the SBSA watchdog instead)

>

> Changes since v1:

> - always fall back to calling gRT_>ResetSystem() if the registered handler

>   returns

> - WARN() if running the SP805 driver with interrupt handling disabled

> - add some R-bs

>

> Cc: Leif Lindholm <leif.lindholm@linaro.org>

> Cc: Sami Mujawar <sami.mujawar@arm.com>

> Cc: Thomas Panakamattam Abraham <thomas.abraham@arm.com>

> Cc: Meenakshi Aggarwal <meenakshi.aggarwal@nxp.com>

> Cc: Udit Kumar <udit.kumar@nxp.com>

> Cc: Matteo Carlini <Matteo.Carlini@arm.com>

> Cc: Nariman Poushin <nariman.poushin@linaro.org>

>

> Ard Biesheuvel (4):

>   ArmPlatformPkg/SP805WatchdogDxe: cosmetic cleanup

>   ArmPlatformPkg/SP805WatchdogDxe: switch to interrupt mode

>   ArmPkg/GenericWatchdogDxe: clean up the code

>   ArmPkg/GenericWatchdogDxe: implement RegisterHandler() method

>


Pushed as  87b920fe22be..ba808d11f6a3

Thanks all
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel