This is a major overhaul of the clk-qoriq driver, which I'm merging via PPC with Stephen Boyd's ack in order to apply subsequent PPC patches that depend on it.
···11* Clock Block on Freescale QorIQ Platforms2233-Freescale qoriq chips take primary clocking input from the external33+Freescale QorIQ chips take primary clocking input from the external44SYSCLK signal. The SYSCLK input (frequency) is multiplied using55multiple phase locked loops (PLL) to create a variety of frequencies66which can then be passed to a variety of internal logic, including···1313Chassis Version Example Chips1414--------------- -------------15151.0 p4080, p5020, p50401616-2.0 t4240, b4860, t10401616+2.0 t4240, b4860171718181. Clock Block Binding19192020Required properties:2121-- compatible: Should contain a specific clock block compatible string2222- and a single chassis clock compatible string.2323- Clock block strings include, but not limited to, one of the:2121+- compatible: Should contain a chip-specific clock block compatible2222+ string and (if applicable) may contain a chassis-version clock2323+ compatible string.2424+2525+ Chip-specific strings are of the form "fsl,<chip>-clockgen", such as:2426 * "fsl,p2041-clockgen"2527 * "fsl,p3041-clockgen"2628 * "fsl,p4080-clockgen"···3230 * "fsl,b4420-clockgen"3331 * "fsl,b4860-clockgen"3432 * "fsl,ls1021a-clockgen"3535- Chassis clock strings include:3333+ Chassis-version clock strings include:3634 * "fsl,qoriq-clockgen-1.0": for chassis 1.0 clocks3735 * "fsl,qoriq-clockgen-2.0": for chassis 2.0 clocks3836- reg: Describes the address of the device's resources within the3937 address space defined by its parent bus, and resource zero4038 represents the clock register set4141-- clock-frequency: Input system clock frequency42394343-Recommended properties:4040+Optional properties:4441- ranges: Allows valid translation between child's address space and4542 parent's. Must be present if the device has sub-nodes.4643- #address-cells: Specifies the number of cells used to represent···4847- #size-cells: Specifies the number of cells used to represent4948 the size of an address. Must be present if the device has5049 sub-nodes and set to 1 if present5050+- clock-frequency: Input system clock frequency (SYSCLK)5151+- clocks: If clock-frequency is not specified, sysclk may be provided5252+ as an input clock. Either clock-frequency or clocks must be5353+ provided.51545252-2. Clock Provider/Consumer Binding5555+2. Clock Provider5656+5757+The clockgen node should act as a clock provider, though in older device5858+trees the children of the clockgen node are the clock providers.5959+6060+When the clockgen node is a clock provider, #clock-cells = <2>.6161+The first cell of the clock specifier is the clock type, and the6262+second cell is the clock index for the specified type.6363+6464+ Type# Name Index Cell6565+ 0 sysclk must be 06666+ 1 cmux index (n in CLKCnCSR)6767+ 2 hwaccel index (n in CLKCGnHWACSR)6868+ 3 fman 0 for fm1, 1 for fm26969+ 4 platform pll 0=pll, 1=pll/2, 2=pll/3, 3=pll/47070+7171+3. Example7272+7373+ clockgen: global-utilities@e1000 {7474+ compatible = "fsl,p5020-clockgen", "fsl,qoriq-clockgen-1.0";7575+ clock-frequency = <133333333>;7676+ reg = <0xe1000 0x1000>;7777+ #clock-cells = <2>;7878+ };7979+8080+ fman@400000 {8181+ ...8282+ clocks = <&clockgen 3 0>;8383+ ...8484+ };8585+}8686+4. Legacy Child Nodes8787+8888+NOTE: These nodes are deprecated. Kernels should continue to support8989+device trees with these nodes, but new device trees should not use them.53905491Most of the bindings are from the common clock binding[1].5592 [1] Documentation/devicetree/bindings/clock/clock-bindings.txt···12182- reg: Should be the offset and length of clock block base address.12283 The length should be 4.12384124124-Example for clock block and clock provider:8585+Legacy Example:12586/ {12687 clockgen: global-utilities@e1000 {12788 compatible = "fsl,p5020-clockgen", "fsl,qoriq-clockgen-1.0";···181142 };182143};183144184184-Example for clock consumer:145145+Example for legacy clock consumer:185146186147/ {187148 cpu0: PowerPC,e5500@0 {
···121121122122config CLK_QORIQ123123 bool "Clock driver for Freescale QorIQ platforms"124124- depends on (PPC_E500MC || ARM) && OF124124+ depends on (PPC_E500MC || ARM || ARM64) && OF125125 ---help---126126 This adds the clock driver support for Freescale QorIQ platforms127127 using common clock framework.