mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-15 22:41:38 +00:00
The registration of the fixed clocks uses the node name as the clock name, causing a clash if two clock nodes have the same name, regardless of the path to the node. Fix the issue by overwriting the clock node names using the value of the "addr" parameter, providing a crude disambiguation. (A bit of string pasting to form "sc16is752_clk_<addr>" would have been nice, but that is outside the abilities of the overlay parameter mechanism.) Also give the sc16is750-i2c overlay the xtal parameter for symmetry. See: https://www.raspberrypi.org/forums/viewtopic.php?f=107&t=235650 Signed-off-by: Phil Elwell <phil@raspberrypi.org>
41 lines
810 B
Plaintext
41 lines
810 B
Plaintext
/dts-v1/;
|
|
/plugin/;
|
|
|
|
/ {
|
|
compatible = "brcm,bcm2835";
|
|
|
|
fragment@0 {
|
|
target = <&i2c1>;
|
|
|
|
frag1: __overlay__ {
|
|
#address-cells = <1>;
|
|
#size-cells = <0>;
|
|
status = "okay";
|
|
|
|
sc16is752: sc16is752@48 {
|
|
compatible = "nxp,sc16is752";
|
|
reg = <0x48>; // i2c address
|
|
clocks = <&sc16is752_clk>;
|
|
interrupt-parent = <&gpio>;
|
|
interrupts = <24 0x2>; /* IRQ_TYPE_EDGE_FALLING */
|
|
gpio-controller;
|
|
#gpio-cells = <0>;
|
|
i2c-max-frequency = <400000>;
|
|
status = "okay";
|
|
|
|
sc16is752_clk: sc16is752_clk {
|
|
compatible = "fixed-clock";
|
|
#clock-cells = <0>;
|
|
clock-frequency = <14745600>;
|
|
};
|
|
};
|
|
};
|
|
};
|
|
|
|
__overrides__ {
|
|
int_pin = <&sc16is752>,"interrupts:0";
|
|
addr = <&sc16is752>,"reg:0",<&sc16is752_clk>,"name";
|
|
xtal = <&sc16is752>,"clock-frequency:0";
|
|
};
|
|
};
|