Commit a9a01e12 authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'linux-watchdog-6.3-rc1' of git://www.linux-watchdog.org/linux-watchdog

Pull watchdog updates from Wim Van Sebroeck:

 - qcom-wdt dt-bindings improvements and additions (like MSM8994 and
   MDM9615)

 - mtk_wdt: Add reset_by_toprgu support

 - devm_clk_get_enabled() helper changes

 - Fix kmemleak in watchdog_cdev_register

 - watchdog sysfs improvements

 - Other fixes and small improvements

* tag 'linux-watchdog-6.3-rc1' of git://www.linux-watchdog.org/linux-watchdog: (52 commits)
  watchdog: at91rm9200: Only warn once about problems in .remove()
  watchdog: mt7621-wdt: avoid ralink architecture dependent code
  watchdog: mt7621-wdt: avoid static global declarations
  dt-bindings: watchdog: mt7621-wdt: add phandle to access system controller registers
  watchdog: sbsa_wdog: Make sure the timeout programming is within the limits
  dt-bindings: watchdog: qcom-wdt: add qcom,apss-wdt-sa8775p compatible
  watchdog: report options in sysfs
  watchdog: report fw_version in sysfs
  dt-bindings: watchdog: fsl-imx: document suspend in wait mode
  watchdog: imx2_wdg: suspend watchdog in WAIT mode
  watchdog: pcwd_usb: Fix attempting to access uninitialized memory
  dt-bindings: watchdog: qcom-wdt: merge MSM timer
  dt-bindings: watchdog: qcom-wdt: allow interrupts
  dt-bindings: watchdog: qcom-wdt: add qcom,kpss-wdt-mdm9615
  dt-bindings: watchdog: qcom-wdt: fix list of MSM timer compatibles
  dt-bindings: watchdog: qcom-wdt: do not allow fallback alone
  dt-bindings: watchdog: qcom-wdt: require fallback for IPQ4019
  watchdog: Fix kmemleak in watchdog_cdev_register
  watchdog: Include <linux/kstrtox.h> when appropriate
  watchdog: at91sam9_wdt: use devm_request_irq to avoid missing free_irq() in error path
  ...
parents c3f9b9fa cf3be7e8
Loading
Loading
Loading
Loading
+13 −0
Original line number Diff line number Diff line
@@ -6,6 +6,19 @@ Description:
		device at boot. It is equivalent to WDIOC_GETBOOTSTATUS of
		ioctl interface.

What:		/sys/class/watchdog/watchdogn/options
Date:		April 2023
Contact:	Thomas Weißschuh
Description:
		It is a read only file. It contains options of watchdog device.

What:		/sys/class/watchdog/watchdogn/fw_version
Date:		April 2023
Contact:	Thomas Weißschuh
Description:
		It is a read only file. It contains firmware version of
		watchdog device.

What:		/sys/class/watchdog/watchdogn/identity
Date:		August 2015
Contact:	Wim Van Sebroeck <wim@iguana.be>
+0 −47
Original line number Diff line number Diff line
* MSM Timer

Properties:

- compatible : Should at least contain "qcom,msm-timer". More specific
               properties specify which subsystem the timers are paired with.

               "qcom,kpss-timer" - krait subsystem
               "qcom,scss-timer" - scorpion subsystem

- interrupts : Interrupts for the debug timer, the first general purpose
               timer, and optionally a second general purpose timer, and
               optionally as well, 2 watchdog interrupts, in that order.

- reg : Specifies the base address of the timer registers.

- clocks: Reference to the parent clocks, one per output clock. The parents
          must appear in the same order as the clock names.

- clock-names: The name of the clocks as free-form strings. They should be in
               the same order as the clocks.

- clock-frequency : The frequency of the debug timer and the general purpose
                    timer(s) in Hz in that order.

Optional:

- cpu-offset : per-cpu offset used when the timer is accessed without the
               CPU remapping facilities. The offset is
               cpu-offset + (0x10000 * cpu-nr).

Example:

       timer@200a000 {
               compatible = "qcom,scss-timer", "qcom,msm-timer";
               interrupts = <1 1 0x301>,
                            <1 2 0x301>,
                            <1 3 0x301>,
                            <1 4 0x301>,
                            <1 5 0x301>;
               reg = <0x0200a000 0x100>;
               clock-frequency = <19200000>,
                                 <32768>;
               clocks = <&sleep_clk>;
               clock-names = "sleep";
               cpu-offset = <0x40000>;
       };
+50 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/watchdog/amlogic,meson6-wdt.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Amlogic Meson6 SoCs Watchdog timer

maintainers:
  - Neil Armstrong <neil.armstrong@linaro.org>
  - Martin Blumenstingl <martin.blumenstingl@googlemail.com>

allOf:
  - $ref: watchdog.yaml#

properties:
  compatible:
    oneOf:
      - enum:
          - amlogic,meson6-wdt
          - amlogic,meson8-wdt
          - amlogic,meson8b-wdt
      - items:
          - const: amlogic,meson8m2-wdt
          - const: amlogic,meson8b-wdt

  interrupts:
    maxItems: 1

  reg:
    maxItems: 1

required:
  - compatible
  - interrupts
  - reg

unevaluatedProperties: false

examples:
  - |
    #include <dt-bindings/interrupt-controller/irq.h>
    #include <dt-bindings/interrupt-controller/arm-gic.h>

    wdt: watchdog@c1109900 {
        compatible = "amlogic,meson6-wdt";
        reg = <0xc1109900 0x8>;
        interrupts = <GIC_SPI 0 IRQ_TYPE_EDGE_RISING>;
        timeout-sec = <10>;
    };
+34 −3
Original line number Diff line number Diff line
@@ -9,9 +9,6 @@ title: Freescale i.MX Watchdog Timer (WDT) Controller
maintainers:
  - Anson Huang <Anson.Huang@nxp.com>

allOf:
  - $ref: "watchdog.yaml#"

properties:
  compatible:
    oneOf:
@@ -55,11 +52,45 @@ properties:
      If present, the watchdog device is configured to assert its
      external reset (WDOG_B) instead of issuing a software reset.

  fsl,suspend-in-wait:
    $ref: /schemas/types.yaml#/definitions/flag
    description: |
      If present, the watchdog device is suspended in WAIT mode
      (Suspend-to-Idle). Only supported on certain devices.

required:
  - compatible
  - interrupts
  - reg

allOf:
  - $ref: watchdog.yaml#
  - if:
      not:
        properties:
          compatible:
            contains:
              enum:
                - fsl,imx25-wdt
                - fsl,imx35-wdt
                - fsl,imx50-wdt
                - fsl,imx51-wdt
                - fsl,imx53-wdt
                - fsl,imx6q-wdt
                - fsl,imx6sl-wdt
                - fsl,imx6sll-wdt
                - fsl,imx6sx-wdt
                - fsl,imx6ul-wdt
                - fsl,imx7d-wdt
                - fsl,imx8mm-wdt
                - fsl,imx8mn-wdt
                - fsl,imx8mp-wdt
                - fsl,imx8mq-wdt
                - fsl,vf610-wdt
    then:
      properties:
        fsl,suspend-in-wait: false

unevaluatedProperties: false

examples:
+55 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/watchdog/gpio-wdt.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: GPIO controlled watchdog

maintainers:
  - Robert Marko <robert.marko@sartura.hr>

properties:
  compatible:
    const: linux,wdt-gpio

  gpios:
    maxItems: 1
    description: GPIO connected to the WDT reset pin

  hw_algo:
    $ref: /schemas/types.yaml#/definitions/string
    description: Algorithm used by the driver
    oneOf:
      - description:
          Either a high-to-low or a low-to-high transition clears the WDT counter.
          The watchdog timer is disabled when GPIO is left floating or connected
          to a three-state buffer.
        const: toggle
      - description:
          Low or high level starts counting WDT timeout, the opposite level
          disables the WDT.
          Active level is determined by the GPIO flags.
        const: level

  hw_margin_ms:
    $ref: /schemas/types.yaml#/definitions/uint32
    description: Maximum time to reset watchdog circuit (in milliseconds)
    minimum: 2
    maximum: 65535

  always-running:
    type: boolean
    description:
      If the watchdog timer cannot be disabled, add this flag to have the driver
      keep toggling the signal without a client.
      It will only cease to toggle the signal when the device is open and the
      timeout elapsed.

required:
  - compatible
  - gpios
  - hw_algo
  - hw_margin_ms

unevaluatedProperties: false
Loading