Commit 6ae19222 authored by Phil Elwell's avatar Phil Elwell Committed by popcornmix
Browse files

overlays: Move "fixed-clock" nodes to the root

Apart from some special cases, device objects are only created for
nodes if they are children of a bus or the root node. "fixed-clock"
is one of the exceptions that will be instantiated wherever it is
found, but only during kernel initialisation - ruling out loading the
overlay at runtime.

Move most of the affected clocks to be children of the root, only
leaving those in overlays that could be multiply instantiated, to avoid
a potential name clash.

See: https://github.com/raspberrypi/linux/issues/3602

Signed-off-by: default avatarPhil Elwell <phil@raspberrypi.com>
parent c249797f
......@@ -24,6 +24,13 @@
regulator-max-microvolt = <1800000>;
regulator-always-on;
};
/* audio external oscillator */
codec_osc: codec_osc {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <12000000>; /* 12 MHz */
};
};
};
......@@ -44,13 +51,6 @@
#size-cells = <0>;
status = "okay";
/* audio external oscillator */
codec_osc: codec_osc {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <12000000>; /* 12 MHz */
};
codec: tlv320aic32x4@18 {
#sound-dai-cells = <0>;
compatible = "ti,tlv320aic32x4";
......
......@@ -30,6 +30,12 @@
regulator-max-microvolt = <3300000>;
regulator-always-on;
};
sc16is752_clk: sc16is752_draws_clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <1843200>;
};
};
pps: pps {
......@@ -78,12 +84,6 @@
pinctrl-names = "default";
pinctrl-0 = <&sc16is752_irq>;
sc16is752_clk: sc16is752_clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <1843200>;
};
};
tla2024: tla2024@48 {
......
......@@ -6,7 +6,7 @@
compatible = "brcm,bcm2835";
fragment@0 {
target = <&clocks>;
target-path = "/";
__overlay__ {
sgtl5000_mclk: sgtl5000_mclk {
compatible = "fixed-clock";
......
......@@ -27,12 +27,6 @@
VDIG-supply = <&imx219_vdig>; /* 1.8v */
VDDL-supply = <&imx219_vddl>; /* 1.2v */
imx219_clk: camera-clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <24000000>;
};
port {
imx219_0: endpoint {
remote-endpoint = <&csi1_ep>;
......@@ -90,6 +84,12 @@
regulator-min-microvolt = <1200000>;
regulator-max-microvolt = <1200000>;
};
imx219_clk: camera-clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <24000000>;
};
};
};
......
......@@ -21,12 +21,6 @@
pwdn-gpios = <&gpio 5 0>;
clocks = <&irs1125_clk>;
irs1125_clk: camera-clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <26000000>;
};
port {
irs1125_0: endpoint {
remote-endpoint = <&csi1_ep>;
......@@ -75,4 +69,15 @@
cam0-pwdn = <&irs1125>,"pwdn-gpios:4";
};
};
fragment@5 {
target-path = "/";
__overlay__ {
irs1125_clk: camera-clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <26000000>;
};
};
};
};
......@@ -35,7 +35,7 @@
/* the clock/oscillator of the can-controller */
fragment@3 {
target-path = "/clocks";
target-path = "/";
__overlay__ {
/* external oscillator of mcp2515 on SPI0.0 */
can0_osc: can0_osc {
......
......@@ -35,7 +35,7 @@
/* the clock/oscillator of the can-controller */
fragment@3 {
target-path = "/clocks";
target-path = "/";
__overlay__ {
/* external oscillator of mcp2515 on spi0.1 */
can1_osc: can1_osc {
......
......@@ -15,7 +15,7 @@
compatible = "brcm,bcm2835";
fragment@0 {
target-path = "/clocks";
target-path = "/";
__overlay__ {
midi_clk: midi_clk {
compatible = "fixed-clock";
......
......@@ -21,12 +21,6 @@
pwdn-gpios = <&gpio 41 1>, <&gpio 32 1>;
clocks = <&ov5647_clk>;
ov5647_clk: camera-clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <25000000>;
};
port {
ov5647_0: endpoint {
remote-endpoint = <&csi1_ep>;
......@@ -77,4 +71,15 @@
cam0-led = <&ov5647>,"pwdn-gpios:16";
};
};
fragment@5 {
target-path = "/";
__overlay__ {
ov5647_clk: camera-clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <25000000>;
};
};
};
};
......@@ -26,12 +26,6 @@
clocks = <&hevc_clk>;
clock-names = "hevc";
hevc_clk: hevc_clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <500000000>;
};
};
};
};
......@@ -53,4 +47,15 @@
};
};
};
fragment@2 {
target-path = "/";
__overlay__ {
hevc_clk: hevc_clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <500000000>;
};
};
};
};
......@@ -38,12 +38,6 @@
#gpio-controller;
#gpio-cells = <2>;
spi-max-frequency = <4000000>;
sc16is752_clk: sc16is752_clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <14745600>;
};
};
};
};
......@@ -55,8 +49,19 @@
};
};
__overrides__ {
fragment@3 {
target-path = "/";
__overlay__ {
sc16is752_clk: sc16is752_spi1_clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <14745600>;
};
};
};
__overrides__ {
int_pin = <&sc16is752>,"interrupts:0";
xtal = <&sc16is752_clk>,"clock-frequency:0";
};
};
};
......@@ -21,12 +21,6 @@
clocks = <&tc358743_clk>;
clock-names = "refclk";
tc358743_clk: bridge-clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <27000000>;
};
port {
tc358743: endpoint {
remote-endpoint = <&csi1_ep>;
......@@ -81,6 +75,17 @@
};
};
fragment@6 {
target-path = "/";
__overlay__ {
tc358743_clk: bridge-clk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <27000000>;
};
};
};
__overrides__ {
4lane = <0>, "-2+3";
link-frequency = <&tc358743>,"link-frequencies#0";
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment