mbox series

[v3,0/4] pseries-wdt: initial support for H_WATCHDOG-based watchdog timers

Message ID 20220713202335.1217647-1-cheloha@linux.ibm.com
Headers show
Series pseries-wdt: initial support for H_WATCHDOG-based watchdog timers | expand

Message

Scott Cheloha July 13, 2022, 8:23 p.m. UTC
PAPR v2.12 defines a new hypercall, H_WATCHDOG.  This patch series
adds support for this hypercall to powerpc/pseries kernels and
introduces a new watchdog driver, "pseries-wdt", for the virtual
timers exposed by the hypercall.

This series is preceded by the following:

RFC v1: https://lore.kernel.org/linux-watchdog/20220413165104.179144-1-cheloha@linux.ibm.com/
RFC v2: https://lore.kernel.org/linux-watchdog/20220509174357.5448-1-cheloha@linux.ibm.com/
PATCH v1: https://lore.kernel.org/linux-watchdog/20220520183552.33426-1-cheloha@linux.ibm.com/
PATCH v2: https://lore.kernel.org/linux-watchdog/20220602175353.68942-1-cheloha@linux.ibm.com/

Changes of note from PATCH v2:

- Don't keep a pointer to the platform device at registration
  time.  We don't use the pointer for anything and we cannot
  hotplug the "device".

- Drop the GETFIELD() and SETFIELD() macros: Michael Ellerman really
  doesn't like them.  Use plain integer constants and custom bitfield
  extraction macros for the capability output instead.

  (After making the change I can see the upside to plain constants.)

- Actually use PSERIES_WDTQ_MAX_NUMBER(): check that the hypervisor
  gave us at least one timer to work with.

- Use MSEC_PER_SEC in a few places instead of the literal 1000 to
  show the reader what we're doing.

- Use "reverse xmas tree" sorting for automatic variable declarations.

- Note where the max_timeout of (UINT_MAX / 1000) comes from.

- Nix email addresses from the MODULE_AUTHOR() macros, they tend to
  rot.

Comments

Michael Ellerman July 29, 2022, 1:01 p.m. UTC | #1
On Wed, 13 Jul 2022 15:23:31 -0500, Scott Cheloha wrote:
> PAPR v2.12 defines a new hypercall, H_WATCHDOG.  This patch series
> adds support for this hypercall to powerpc/pseries kernels and
> introduces a new watchdog driver, "pseries-wdt", for the virtual
> timers exposed by the hypercall.
> 
> This series is preceded by the following:
> 
> [...]

Applied to powerpc/next.

[1/4] powerpc/pseries: hvcall.h: add H_WATCHDOG opcode, H_NOOP return code
      https://git.kernel.org/powerpc/c/c6b2bd262b33aa2451f52aec2190131d1762945a
[2/4] powerpc/pseries: add FW_FEATURE_WATCHDOG flag
      https://git.kernel.org/powerpc/c/1621563ec62ff143c7b817dd5eab0884cdfaf89d
[3/4] powerpc/pseries: register pseries-wdt device with platform bus
      https://git.kernel.org/powerpc/c/578030bfe117060bf86c81aaa7b3faead4589810
[4/4] watchdog/pseries-wdt: initial support for H_WATCHDOG-based watchdog timers
      https://git.kernel.org/powerpc/c/69472ffa6575e3a1c1e3324dd06395af0f63eb71

cheers