mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-06 01:49:46 +00:00
In order to prevent confusing problems where pin configuration is not be applied, an upcoming change to the overlaycheck utility will add a check that all added pin groups are in some way referenced by the overlay. Before that can be done, it is necessary to ensure that all existing overlays pass that test. This patch modifies some overlays by adding the required "pinctrl-0" properties, but for others that are just setting GPIOs to inputs and outputs, where those same GPIOs are declared by <name>-gpios properties, it is better to drop the pin groups and let the GPIO subsystem set up the GPIOs as required. Removing this duplication may be helpful in the future should we ever decide to enable the exclusive GPIO vs pinctrl locking (.strict in struct pinmux_ops). See: https://forums.raspberrypi.com/viewtopic.php?t=393742 Signed-off-by: Phil Elwell <phil@raspberrypi.com>
53 lines
1.1 KiB
Plaintext
53 lines
1.1 KiB
Plaintext
/dts-v1/;
|
|
/plugin/;
|
|
|
|
/* Overlay for ChipCap 2 on i2c */
|
|
#include <dt-bindings/gpio/gpio.h>
|
|
#include <dt-bindings/interrupt-controller/irq.h>
|
|
|
|
/ {
|
|
compatible = "brcm,bcm2835";
|
|
|
|
fragment@0 {
|
|
target = <&i2c1>;
|
|
__overlay__ {
|
|
#address-cells = <1>;
|
|
#size-cells = <0>;
|
|
status = "okay";
|
|
|
|
chipcap2: chipcap2@28 {
|
|
compatible = "amphenol,cc2d23s";
|
|
reg = <0x28>;
|
|
interrupt-parent = <&gpio>;
|
|
interrupts = <4 IRQ_TYPE_EDGE_RISING>,
|
|
<5 IRQ_TYPE_EDGE_RISING>,
|
|
<6 IRQ_TYPE_EDGE_RISING>;
|
|
interrupt-names = "ready", "low", "high";
|
|
vdd-supply = <&chipcap2_reg>;
|
|
status = "okay";
|
|
};
|
|
};
|
|
};
|
|
|
|
fragment@1 {
|
|
target-path = "/";
|
|
__overlay__ {
|
|
chipcap2_reg: chipcap2_reg {
|
|
compatible = "regulator-fixed";
|
|
regulator-name = "chipcap2_reg";
|
|
regulator-min-microvolt = <3300000>;
|
|
regulator-max-microvolt = <3300000>;
|
|
gpio = <&gpio 26 GPIO_ACTIVE_HIGH>;
|
|
enable-active-high;
|
|
};
|
|
};
|
|
};
|
|
|
|
__overrides__ {
|
|
ready_pin = <&chipcap2>, "interrupts:0";
|
|
low_pin = <&chipcap2>, "interrupts:8";
|
|
high_pin = <&chipcap2>, "interrupts:16";
|
|
reg_pin = <&chipcap2_reg>, "gpio:4";
|
|
};
|
|
};
|