ODROID-N2/C4: dtbs/dtbo: add PPS via GPIO pin #11/#12

This patch addes two device tree overlay files in order to run PPS via
GPIO pins populated in GPIO pin header #11 and #12. By adding the device
tree overlay file to 'config.ini', the driver will be enabled and PPS
will be registered.

In 'config.ini',

	overlays="pps-gpio_p12"

Signed-off-by: Dongjin Kim <tobetter@gmail.com>
Change-Id: I2e13c8de7592bd117bb311f3fe2c1bc50901785e
This commit is contained in:
Dongjin Kim
2023-06-07 14:15:59 +09:00
parent bc5ec7ebd4
commit 68fedaf86c
7 changed files with 81 additions and 1 deletions

View File

@@ -20,6 +20,8 @@ dtbo-$(CONFIG_ARCH_MESON64_ODROIDC4) += spi0.dtbo \
esp8089.dtbo \
sdio.dtbo \
fanspeed-full.dtbo \
pps-gpio_p11.dtbo \
pps-gpio_p12.dtbo \
pwm_ab.dtbo \
pwm_cd.dtbo \
pwm_ef.dtbo \

View File

@@ -0,0 +1,19 @@
/dts-v1/;
/plugin/;
#include <dt-bindings/gpio/meson-g12a-gpio.h>
#include <dt-bindings/gpio/gpio.h>
/ {
fragment@0 {
target-path = "/";
__overlay__ {
pps: pps {
compatible = "pps-gpio";
gpios = <&gpio GPIOX_3 GPIO_ACTIVE_HIGH>;
status = "okay";
};
};
};
};

View File

@@ -0,0 +1,19 @@
/dts-v1/;
/plugin/;
#include <dt-bindings/gpio/meson-g12a-gpio.h>
#include <dt-bindings/gpio/gpio.h>
/ {
fragment@0 {
target-path = "/";
__overlay__ {
pps: pps {
compatible = "pps-gpio";
gpios = <&gpio GPIOX_16 GPIO_ACTIVE_HIGH>;
status = "okay";
};
};
};
};

View File

@@ -18,6 +18,8 @@ dtbo-$(CONFIG_ARCH_MESON64_ODROIDN2) += spi0.dtbo \
fanspeed-full.dtbo \
gpio_spdif.dtbo \
pcf8563.dtbo \
pps-gpio_p11.dtbo \
pps-gpio_p12.dtbo \
pwm_cd.dtbo \
pwm_ef.dtbo \
pwm_c-pwmfan.dtbo \

View File

@@ -0,0 +1,19 @@
/dts-v1/;
/plugin/;
#include <dt-bindings/gpio/meson-g12a-gpio.h>
#include <dt-bindings/gpio/gpio.h>
/ {
fragment@0 {
target-path = "/";
__overlay__ {
pps: pps {
compatible = "pps-gpio";
gpios = <&gpio GPIOX_3 GPIO_ACTIVE_HIGH>;
status = "okay";
};
};
};
};

View File

@@ -0,0 +1,19 @@
/dts-v1/;
/plugin/;
#include <dt-bindings/gpio/meson-g12a-gpio.h>
#include <dt-bindings/gpio/gpio.h>
/ {
fragment@0 {
target-path = "/";
__overlay__ {
pps: pps {
compatible = "pps-gpio";
gpios = <&gpio GPIOX_16 GPIO_ACTIVE_HIGH>;
status = "okay";
};
};
};
};

View File

@@ -3327,7 +3327,7 @@ CONFIG_PPS=y
# CONFIG_PPS_CLIENT_KTIMER is not set
# CONFIG_PPS_CLIENT_LDISC is not set
# CONFIG_PPS_CLIENT_PARPORT is not set
# CONFIG_PPS_CLIENT_GPIO is not set
CONFIG_PPS_CLIENT_GPIO=y
#
# PPS generators support