Commit c23b7517 authored by Rafael J. Wysocki's avatar Rafael J. Wysocki
Browse files
Pull thermal control material for 5.19-rc1 from Daniel Lezcano:

 - Add the new k3 j72xx bangdap driver and the corresponding bindings (Keerthy)

 - Fix the missing of_node_put() in the SC iMX driver at probe timer (Miaoqian Lin)

 - Fix memory leak in __thermal_cooling_device_register() when device_register()
   fails by calling thermal_cooling_device_destroy_sysfs() (Yang Yingliang)

 - Add sc8180x and sc8280xp compatible string in the DT bindings and lMH support
   for QCom tsens driver (Bjorn Andersson)

 - Fix OTP Calibration Register values conforming to the documentation on RZ/G2L
   and bindings documentation for RZ/G2UL (Biju Das)

 - Fix type in kerneldoc description for __thermal_bind_params (Corentin Labbe)

 - Remove unneeded semi colon in libthermal and tools thermal as reported by
   cocci (Jiapeng Chong)

 - Fix potential NULL dereference in sr_thermal_probe() on Broadcom platform
   (Zheng Yongjun)

 - Add thermal library and thermal tools to encapsulate the netlink into event
   based callbacks (Daniel Lezcano)

 - Add change mode ops for the thermal-of sensor (Manaf Meethalavalappu
   Pallikunhi)

 - Fix non negative value support by preventing the value to be clamp to zero
   (Stefan Wahren)

 - Add compatible string and DT bindings for MSM8960 tsens driver (Dmitry
   Baryshkov)

 - Add hwmon support for K3 driver (Massimiliano Minella)

 - Refactor and add multiple generations support for QCom ADC driver (Jishnu
   Prakash)

 - Use platform_get_irq_optional() to get the interrupt on RCar driver and
   document Document RZ/V2L bindings (Lad Prabhakar)

* tag 'thermal-v5.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/thermal/linux: (28 commits)
  thermal: k3_j72xx_bandgap: Add the bandgap driver support
  dt-bindings: thermal: k3-j72xx: Add VTM bindings documentation
  thermal/drivers/imx_sc_thermal: Fix refcount leak in imx_sc_thermal_probe
  thermal/core: Fix memory leak in __thermal_cooling_device_register()
  dt-bindings: thermal: tsens: Add sc8280xp compatible
  dt-bindings: thermal: lmh: Add Qualcomm sc8180x compatible
  thermal/drivers/qcom/lmh: Add sc8180x compatible
  thermal/drivers/rz2gl: Fix OTP Calibration Register values
  dt-bindings: thermal: rzg2l-thermal: Document RZ/G2UL bindings
  thermal: thermal_of: fix typo on __thermal_bind_params
  tools/thermal: remove unneeded semicolon
  tools/lib/thermal: remove unneeded semicolon
  thermal/drivers/broadcom: Fix potential NULL dereference in sr_thermal_probe
  tools/thermal: Add thermal daemon skeleton
  tools/thermal: Add a temperature capture tool
  tools/thermal: Add util library
  tools/lib/thermal: Add a thermal library
  thermal/drivers/thermal_of: Add change_mode ops support for thermal_of sensor
  thermal/drivers/bcm2711: Don't clamp temperature at zero
  thermal/drivers/tsens: Add compat string for the qcom,msm8960
  ...
parents 7b145802 ffcb2fc8
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -18,6 +18,7 @@ description:
properties:
  compatible:
    enum:
      - qcom,sc8180x-lmh
      - qcom,sdm845-lmh
      - qcom,sm8150-lmh

+108 −2
Original line number Diff line number Diff line
@@ -10,7 +10,9 @@ maintainers:

properties:
  compatible:
    const: qcom,spmi-adc-tm5
    enum:
      - qcom,spmi-adc-tm5
      - qcom,spmi-adc-tm5-gen2

  reg:
    maxItems: 1
@@ -33,6 +35,7 @@ properties:
  qcom,avg-samples:
    $ref: /schemas/types.yaml#/definitions/uint32
    description: Number of samples to be used for measurement.
            Not applicable for Gen2 ADC_TM peripheral.
    enum:
      - 1
      - 2
@@ -45,6 +48,7 @@ properties:
    $ref: /schemas/types.yaml#/definitions/uint32
    description: This parameter is used to decrease ADC sampling rate.
            Quicker measurements can be made by reducing decimation ratio.
            Not applicable for Gen2 ADC_TM peripheral.
    enum:
      - 250
      - 420
@@ -93,6 +97,29 @@ patternProperties:
          - const: 1
          - enum: [ 1, 3, 4, 6, 20, 8, 10 ]

      qcom,avg-samples:
        $ref: /schemas/types.yaml#/definitions/uint32
        description: Number of samples to be used for measurement.
          This property in child node is applicable only for Gen2 ADC_TM peripheral.
        enum:
          - 1
          - 2
          - 4
          - 8
          - 16
        default: 1

      qcom,decimation:
        $ref: /schemas/types.yaml#/definitions/uint32
        description: This parameter is used to decrease ADC sampling rate.
          Quicker measurements can be made by reducing decimation ratio.
          This property in child node is applicable only for Gen2 ADC_TM peripheral.
        enum:
          - 85
          - 340
          - 1360
        default: 1360

    required:
      - reg
      - io-channels
@@ -100,6 +127,31 @@ patternProperties:
    additionalProperties:
      false

allOf:
  - if:
      properties:
        compatible:
          contains:
            const: qcom,spmi-adc-tm5

    then:
      patternProperties:
        "^([-a-z0-9]*)@[0-7]$":
          properties:
            qcom,decimation: false
            qcom,avg-samples: false

  - if:
      properties:
        compatible:
          contains:
            const: qcom,spmi-adc-tm5-gen2

    then:
      properties:
        qcom,avg-samples: false
        qcom,decimation: false

required:
  - compatible
  - reg
@@ -124,7 +176,7 @@ examples:
            #size-cells = <0>;
            #io-channel-cells = <1>;

            /* Other propreties are omitted */
            /* Other properties are omitted */
            conn-therm@4f {
                reg = <ADC5_AMUX_THM3_100K_PU>;
                qcom,ratiometric;
@@ -148,4 +200,58 @@ examples:
            };
        };
    };

  - |
    #include <dt-bindings/iio/qcom,spmi-adc7-pmk8350.h>
    #include <dt-bindings/iio/qcom,spmi-adc7-pm8350.h>
    #include <dt-bindings/interrupt-controller/irq.h>
    spmi_bus {
        #address-cells = <1>;
        #size-cells = <0>;
        pmk8350_vadc: adc@3100 {
            reg = <0x3100>;
            compatible = "qcom,spmi-adc7";
            #address-cells = <1>;
            #size-cells = <0>;
            #io-channel-cells = <1>;

            /* Other properties are omitted */
            xo-therm@44 {
                reg = <PMK8350_ADC7_AMUX_THM1_100K_PU>;
                qcom,ratiometric;
                qcom,hw-settle-time = <200>;
            };

            conn-therm@47 {
                reg = <PM8350_ADC7_AMUX_THM4_100K_PU>;
                qcom,ratiometric;
                qcom,hw-settle-time = <200>;
            };
        };

        pmk8350_adc_tm: adc-tm@3400 {
            compatible = "qcom,spmi-adc-tm5-gen2";
            reg = <0x3400>;
            interrupts = <0x0 0x34 0x0 IRQ_TYPE_EDGE_RISING>;
            #thermal-sensor-cells = <1>;
            #address-cells = <1>;
            #size-cells = <0>;

            pmk8350-xo-therm@0 {
                reg = <0>;
                io-channels = <&pmk8350_vadc PMK8350_ADC7_AMUX_THM1_100K_PU>;
                qcom,decimation = <340>;
                qcom,ratiometric;
                qcom,hw-settle-time-us = <200>;
            };

            conn-therm@1 {
                reg = <1>;
                io-channels = <&pmk8350_vadc PM8350_ADC7_AMUX_THM4_100K_PU>;
                qcom,avg-samples = <2>;
                qcom,ratiometric;
                qcom,hw-settle-time-us = <200>;
            };
        };
    };
...
+4 −1
Original line number Diff line number Diff line
@@ -19,10 +19,11 @@ description: |
properties:
  compatible:
    oneOf:
      - description: msm9860 TSENS based
      - description: msm8960 TSENS based
        items:
          - enum:
              - qcom,ipq8064-tsens
              - qcom,msm8960-tsens

      - description: v0.1 of TSENS
        items:
@@ -49,6 +50,7 @@ properties:
              - qcom,sc7180-tsens
              - qcom,sc7280-tsens
              - qcom,sc8180x-tsens
              - qcom,sc8280xp-tsens
              - qcom,sdm630-tsens
              - qcom,sdm845-tsens
              - qcom,sm8150-tsens
@@ -116,6 +118,7 @@ allOf:
              - qcom,ipq8064-tsens
              - qcom,mdm9607-tsens
              - qcom,msm8916-tsens
              - qcom,msm8960-tsens
              - qcom,msm8974-tsens
              - qcom,msm8976-tsens
              - qcom,qcs404-tsens
+2 −0
Original line number Diff line number Diff line
@@ -17,7 +17,9 @@ properties:
  compatible:
    items:
      - enum:
          - renesas,r9a07g043-tsu # RZ/G2UL
          - renesas,r9a07g044-tsu # RZ/G2{L,LC}
          - renesas,r9a07g054-tsu # RZ/V2L
      - const: renesas,rzg2l-tsu

  reg:
+63 −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/thermal/ti,j72xx-thermal.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Texas Instruments J72XX VTM (DTS) binding

maintainers:
  - Keerthy <j-keerthy@ti.com>

properties:
  compatible:
    enum:
      - ti,j721e-vtm
      - ti,j7200-vtm

  reg:
    items:
      - description: VTM cfg1 register space
      - description: VTM cfg2 register space
      - description: VTM efuse register space

  power-domains:
    maxItems: 1

  "#thermal-sensor-cells":
    const: 1

required:
  - compatible
  - reg
  - power-domains
  - "#thermal-sensor-cells"

additionalProperties: false

examples:
  - |
    #include <dt-bindings/soc/ti,sci_pm_domain.h>
    wkup_vtm0: thermal-sensor@42040000 {
        compatible = "ti,j721e-vtm";
        reg = <0x42040000 0x350>,
              <0x42050000 0x350>,
              <0x43000300 0x10>;
        power-domains = <&k3_pds 154 TI_SCI_PD_EXCLUSIVE>;
        #thermal-sensor-cells = <1>;
    };

    mpu_thermal: mpu-thermal {
        polling-delay-passive = <250>; /* milliseconds */
        polling-delay = <500>; /* milliseconds */
        thermal-sensors = <&wkup_vtm0 0>;

        trips {
            mpu_crit: mpu-crit {
                temperature = <125000>; /* milliCelsius */
                hysteresis = <2000>; /* milliCelsius */
                type = "critical";
            };
        };
    };
...
Loading