Commit 34761956 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull clk updates from Stephen Boyd:
 "There's not much to see in the core framework this time around.
  Instead the majority of the diff is the normal collection of driver
  additions for new SoCs and non-critical clk data fixes and updates.
  The framework must be middle aged.

  The two biggest directories in the diffstat show that the Qualcomm and
  Unisoc support added a handful of big drivers for new SoCs but that's
  not really the whole story because those new drivers tend to add large
  numbers of lines of clk data. There's a handful of AT91 clk drivers
  added this time around too and a bunch of improvements to drivers like
  the i.MX driver. All around lots of updates and fixes in various clk
  drivers which is good to see.

  The core framework has only one real major change which has been
  baking in next for the past couple months. It fixes the framework so
  that it stops caching a clk's phase when the phase clk_op returns an
  error. Before this change we would consider some negative errno as a
  phase and that just doesn't make sense.

  Core:
   - Don't show clk phase when it is invalid

  New Drivers:
   - Add support for Unisoc SC9863A clks
   - Qualcomm SM8250 RPMh and MSM8976 RPM clks
   - Qualcomm SM8250 Global Clock Controller (GCC) support
   - Qualcomm SC7180 Modem Clock Controller (MSS CC) support
   - EHRPWM's TimeBase clock(TBCLK) for TI AM654 SoCs
   - Support PMC clks on at91sam9n12, at91rm9200, sama5d3, and
     at91sam9g45 SoCs

  Updates:
   - GPU GX GDSC support on Qualcomm sc7180
   - Fixes and improvements for the Marvell MMP2/MMP3 SoC clk drivers
   - A series from Anson to convert i.MX8 clock bindings to json-schema
   - Update i.MX pll14xx driver to include new frequency entries for
     pll1443x table, and return error for invalid PLL type
   - Add missing of_node_put() call for a number of i.MX clock drivers
   - Drop flag CLK_IS_CRITICAL from 'A53_CORE' mux clock, as we already
     have the flag on its child cpu clock
   - Fix a53 cpu clock for i.MX8 drivers to get it source from ARM PLL
     via CORE_SEL slice, and source from A53 CCM clk root when we need
     to change ARM PLL frequency. Thus, we can support core running
     above 1GHz safely
   - Update i.MX pfdv2 driver to check zero rate and use determine_rate
     for getting the best rate
   - Add CLKO2 for imx8mm, SNVS clock for imx8mn, and PXP clock for
     imx7d
   - Remove PMC clks from Tegra clk driver
   - Improved clock/reset handling for the Renesas R-Car USB2 Clock
     Selector
   - Conversion to json-schema of the Renesas CPG/MSSR DT bindings
   - Add Crypto clocks on Renesas R-Car M3-W/W+, M3-N, E3, and D3
   - Add RPC (QSPI/HyperFLASH) clocks on Renesas R-Car H3, M3-W/W+, and
     M3-N
   - Update Amlogic audio clock gate hierarchy for meson8 and gxbb
   - Update Amlogic g12a spicc clock sources
   - Support for Ingenic X1000 TCU clks"

* tag 'clk-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux: (146 commits)
  clk: sprd: fix to get a correct ibias of pll
  dt-bindings: imx8mm-clock: Fix the file path
  dt-bindings: imx8mq-clock: Fix the file path
  clk: qcom: rpmh: Drop unnecessary semicolons
  clk: qcom: rpmh: Simplify clk_rpmh_bcm_send_cmd()
  clk: tegra: Use NULL for pointer initialization
  clk: sprd: add clocks support for SC9863A
  clk: sprd: support to get regmap from parent node
  clk: sprd: Add macros for referencing parents without strings
  clk: sprd: Add dt-bindings include file for SC9863A
  dt-bindings: clk: sprd: add bindings for sc9863a clock controller
  dt-bindings: clk: sprd: rename the common file name sprd.txt to SoC specific
  clk: sprd: add gate for pll clocks
  MAINTAINERS: dt: update reference for arm-integrator.txt
  clk: mmp2: Fix bit masks for LCDC I/O and pixel clocks
  clk: mmp2: Add clock for fifth SD HCI on MMP3
  dt-bindings: marvell,mmp2: Add clock id for the fifth SD HCI on MMP3
  clk: mmp2: Add clocks for the thermal sensors
  dt-bindings: marvell,mmp2: Add clock ids for the thermal sensors
  clk: mmp2: add the GPU clocks
  ...
parents aa1a8ce5 28ecaf1c
Loading
Loading
Loading
Loading
+103 −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/clock/arm,syscon-icst.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: ARM System Controller ICST Clocks

maintainers:
  - Linus Walleij <linusw@kernel.org>

description: |
  The ICS525 and ICS307 oscillators are produced by Integrated
  Devices Technology (IDT). ARM integrated these oscillators deeply into their
  reference designs by adding special control registers that manage such
  oscillators to their system controllers.

  The various ARM system controllers contain logic to serialize and initialize
  an ICST clock request after a write to the 32 bit register at an offset
  into the system controller. Furthermore, to even be able to alter one of
  these frequencies, the system controller must first be unlocked by
  writing a special token to another offset in the system controller.

  Some ARM hardware contain special versions of the serial interface that only
  connects the low 8 bits of the VDW (missing one bit), hard-wires RDW to
  different values and sometimes also hard-wires the output divider. They
  therefore have special compatible strings as per this table (the OD value is
  the value on the pins, not the resulting output divider).

  In the core modules and logic tiles, the ICST is a configurable clock fed
  from a 24 MHz clock on the motherboard (usually the main crystal) used for
  generating e.g. video clocks. It is located on the core module and there is
  only one of these. This clock node must be a subnode of the core module.

  Hardware variant         RDW     OD          VDW

  Integrator/AP            22      1           Bit 8 0, rest variable
  integratorap-cm

  Integrator/AP            46      3           Bit 8 0, rest variable
  integratorap-sys

  Integrator/AP            22 or   1           17 or (33 or 25 MHz)
  integratorap-pci         14      1           14

  Integrator/CP            22      variable    Bit 8 0, rest variable
  integratorcp-cm-core

  Integrator/CP            22      variable    Bit 8 0, rest variable
  integratorcp-cm-mem

  The ICST oscillator must be provided inside a system controller node.

properties:
  "#clock-cells":
    const: 0

  compatible:
    enum:
      - arm,syscon-icst525
      - arm,syscon-icst307
      - arm,syscon-icst525-integratorap-cm
      - arm,syscon-icst525-integratorap-sys
      - arm,syscon-icst525-integratorap-pci
      - arm,syscon-icst525-integratorcp-cm-core
      - arm,syscon-icst525-integratorcp-cm-mem
      - arm,integrator-cm-auxosc
      - arm,versatile-cm-auxosc
      - arm,impd-vco1
      - arm,impd-vco2

  clocks:
    description: Parent clock for the ICST VCO
    maxItems: 1

  clock-output-names:
    maxItems: 1

  lock-offset:
    $ref: '/schemas/types.yaml#/definitions/uint32'
    description: Offset to the unlocking register for the oscillator

  vco-offset:
    $ref: '/schemas/types.yaml#/definitions/uint32'
    description: Offset to the VCO register for the oscillator

required:
  - "#clock-cells"
  - compatible
  - clocks

examples:
  - |
    vco1: clock@00 {
      compatible = "arm,impd1-vco1";
      #clock-cells = <0>;
      lock-offset = <0x08>;
      vco-offset = <0x00>;
      clocks = <&sysclk>;
      clock-output-names = "IM-PD1-VCO1";
    };

...
+0 −34
Original line number Diff line number Diff line
Clock bindings for ARM Integrator and Versatile Core Module clocks

Auxiliary Oscillator Clock

This is a configurable clock fed from a 24 MHz chrystal,
used for generating e.g. video clocks. It is located on the
core module and there is only one of these.

This clock node *must* be a subnode of the core module, since
it obtains the base address for it's address range from its
parent node.


Required properties:
- compatible: must be "arm,integrator-cm-auxosc" or "arm,versatile-cm-auxosc"
- #clock-cells: must be <0>

Optional properties:
- clocks: parent clock(s)

Example:

core-module@10000000 {
	xtal24mhz: xtal24mhz@24M {
		#clock-cells = <0>;
		compatible = "fixed-clock";
		clock-frequency = <24000000>;
	};
	auxosc: cm_aux_osc@25M {
		#clock-cells = <0>;
		compatible = "arm,integrator-cm-auxosc";
		clocks = <&xtal24mhz>;
	};
};
+0 −70
Original line number Diff line number Diff line
ARM System Controller ICST clocks

The ICS525 and ICS307 oscillators are produced by Integrated Devices
Technology (IDT). ARM integrated these oscillators deeply into their
reference designs by adding special control registers that manage such
oscillators to their system controllers.

The various ARM system controllers contain logic to serialize and initialize
an ICST clock request after a write to the 32 bit register at an offset
into the system controller. Furthermore, to even be able to alter one of
these frequencies, the system controller must first be unlocked by
writing a special token to another offset in the system controller.

Some ARM hardware contain special versions of the serial interface that only
connects the low 8 bits of the VDW (missing one bit), hardwires RDW to
different values and sometimes also hardwire the output divider. They
therefore have special compatible strings as per this table (the OD value is
the value on the pins, not the resulting output divider):

Hardware variant:        RDW     OD          VDW

Integrator/AP            22      1           Bit 8 0, rest variable
integratorap-cm

Integrator/AP            46      3           Bit 8 0, rest variable
integratorap-sys

Integrator/AP            22 or   1           17 or (33 or 25 MHz)
integratorap-pci         14      1           14

Integrator/CP            22      variable    Bit 8 0, rest variable
integratorcp-cm-core

Integrator/CP            22      variable    Bit 8 0, rest variable
integratorcp-cm-mem

The ICST oscillator must be provided inside a system controller node.

Required properties:
- compatible: must be one of
  "arm,syscon-icst525"
  "arm,syscon-icst307"
  "arm,syscon-icst525-integratorap-cm"
  "arm,syscon-icst525-integratorap-sys"
  "arm,syscon-icst525-integratorap-pci"
  "arm,syscon-icst525-integratorcp-cm-core"
  "arm,syscon-icst525-integratorcp-cm-mem"
- lock-offset: the offset address into the system controller where the
  unlocking register is located
- vco-offset: the offset address into the system controller where the
  ICST control register is located (even 32 bit address)
- #clock-cells: must be <0>
- clocks: parent clock, since the ICST needs a parent clock to derive its
  frequency from, this attribute is compulsory.

Example:

syscon: syscon@10000000 {
	compatible = "syscon";
	reg = <0x10000000 0x1000>;

	oscclk0: osc0@c {
		compatible = "arm,syscon-icst307";
		#clock-cells = <0>;
		lock-offset = <0x20>;
		vco-offset = <0x0c>;
		clocks = <&xtal24mhz>;
	};
	(...)
};
+0 −29
Original line number Diff line number Diff line
* Clock bindings for NXP i.MX8M Mini

Required properties:
- compatible: Should be "fsl,imx8mm-ccm"
- reg: Address and length of the register set
- #clock-cells: Should be <1>
- clocks: list of clock specifiers, must contain an entry for each required
          entry in clock-names
- clock-names: should include the following entries:
    - "osc_32k"
    - "osc_24m"
    - "clk_ext1"
    - "clk_ext2"
    - "clk_ext3"
    - "clk_ext4"

clk: clock-controller@30380000 {
	compatible = "fsl,imx8mm-ccm";
	reg = <0x0 0x30380000 0x0 0x10000>;
	#clock-cells = <1>;
	clocks = <&osc_32k>, <&osc_24m>, <&clk_ext1>, <&clk_ext2>,
		 <&clk_ext3>, <&clk_ext4>;
	clock-names = "osc_32k", "osc_24m", "clk_ext1", "clk_ext2",
		      "clk_ext3", "clk_ext4";
};

The clock consumer should specify the desired clock by having the clock
ID in its "clocks" phandle cell. See include/dt-bindings/clock/imx8mm-clock.h
for the full list of i.MX8M Mini clock IDs.
+68 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: GPL-2.0
%YAML 1.2
---
$id: http://devicetree.org/schemas/clock/imx8mm-clock.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: NXP i.MX8M Mini Clock Control Module Binding

maintainers:
  - Anson Huang <Anson.Huang@nxp.com>

description: |
  NXP i.MX8M Mini clock control module is an integrated clock controller, which
  generates and supplies to all modules.

properties:
  compatible:
    const: fsl,imx8mm-ccm

  reg:
    maxItems: 1

  clocks:
    items:
      - description: 32k osc
      - description: 24m osc
      - description: ext1 clock input
      - description: ext2 clock input
      - description: ext3 clock input
      - description: ext4 clock input

  clock-names:
    items:
      - const: osc_32k
      - const: osc_24m
      - const: clk_ext1
      - const: clk_ext2
      - const: clk_ext3
      - const: clk_ext4

  '#clock-cells':
    const: 1
    description:
      The clock consumer should specify the desired clock by having the clock
      ID in its "clocks" phandle cell. See include/dt-bindings/clock/imx8mm-clock.h
      for the full list of i.MX8M Mini clock IDs.

required:
  - compatible
  - reg
  - clocks
  - clock-names
  - '#clock-cells'

examples:
  # Clock Control Module node:
  - |
    clk: clock-controller@30380000 {
        compatible = "fsl,imx8mm-ccm";
        reg = <0x30380000 0x10000>;
        #clock-cells = <1>;
        clocks = <&osc_32k>, <&osc_24m>, <&clk_ext1>, <&clk_ext2>,
                 <&clk_ext3>, <&clk_ext4>;
        clock-names = "osc_32k", "osc_24m", "clk_ext1", "clk_ext2",
                      "clk_ext3", "clk_ext4";
    };

...
Loading