From 547f4b3b06a2d312ae4c4916ed511d19f16f6b67 Mon Sep 17 00:00:00 2001 From: Patrick Murphy Date: Thu, 13 May 2021 02:22:54 -0500 Subject: added mtac-003 overlay support for mtcdt and mtcdt3ac platforms --- Makefile | 3 ++- mtcdt/alt-mtcdt-0.0.dtso | 66 ---------------------------------------------- mtcdt/ap1-gpiob-0.0.dtso | 43 ++++++++++++++++++++++++++++++ mtcdt/ap1-xdot-0.0.dtso | 35 ------------------------ mtcdt/ap2-gpiob-0.0.dtso | 43 ++++++++++++++++++++++++++++++ mtcdt/ap2-xdot-0.0.dtso | 36 ------------------------- mtcdt/mtcdt-0.0.dtso | 66 ---------------------------------------------- mtcdt/mtcdt-gpios.0.0.dtso | 66 ---------------------------------------------- mtcpmhs/ap1-gpiob-0.0.dtso | 39 +++++++++++++++++++++++++++ mtcpmhs/ap2-gpiob-0.0.dtso | 39 +++++++++++++++++++++++++++ 10 files changed, 166 insertions(+), 270 deletions(-) delete mode 100644 mtcdt/alt-mtcdt-0.0.dtso create mode 100644 mtcdt/ap1-gpiob-0.0.dtso delete mode 100644 mtcdt/ap1-xdot-0.0.dtso create mode 100644 mtcdt/ap2-gpiob-0.0.dtso delete mode 100644 mtcdt/ap2-xdot-0.0.dtso delete mode 100644 mtcdt/mtcdt-0.0.dtso delete mode 100644 mtcdt/mtcdt-gpios.0.0.dtso create mode 100644 mtcpmhs/ap1-gpiob-0.0.dtso create mode 100644 mtcpmhs/ap2-gpiob-0.0.dtso diff --git a/Makefile b/Makefile index 8cefc6a..a9fcdd1 100644 --- a/Makefile +++ b/Makefile @@ -4,6 +4,7 @@ KERNEL_BUILD_DIR?=$(KERNEL_DIR) # Need a dtc new enough to handle the DTC options. DTC?=/usr/bin/dtc +MTCPMHS_DTBO_OBJECTS:= $(patsubst %.dtso,%.dtbo,$(wildcard mtcpmhs/*.dtso)) MTCDT_DTBO_OBJECTS:= $(patsubst %.dtso,%.dtbo,$(wildcard mtcdt/*.dtso)) MTRV1_DTBO_OBJECTS:= $(patsubst %.dtso,%.dtbo,$(wildcard mtrv1/*.dtso)) MTCAP_DTBO_OBJECTS:= $(patsubst %.dtso,%.dtbo,$(wildcard mtcap/*.dtso)) @@ -20,7 +21,7 @@ MTCAP_DTBO_OBJECTS:= $(patsubst %.dtso,%.dtbo,$(wildcard mtcap/*.dtso)) mtcdt_dtbos: $(MTCDT_DTBO_OBJECTS) mtrv1_dtbos: $(MTRV1_DTBO_OBJECTS) mtcap_dtbos: $(MTCAP_DTBO_OBJECTS) - +mtcpmhs_dtbos: $(MTCPMHS_DTBO_OBJECTS) .PHONY: clean clean: rm -f */*.dtbo *.itb diff --git a/mtcdt/alt-mtcdt-0.0.dtso b/mtcdt/alt-mtcdt-0.0.dtso deleted file mode 100644 index 3f51855..0000000 --- a/mtcdt/alt-mtcdt-0.0.dtso +++ /dev/null @@ -1,66 +0,0 @@ -/* - * DTS overlay for MTCDT 0.0 hardware version. - */ - -/* - * Location(s): - * Put: MTCDT/0.0/alt-mtcdt.dtbo - */ - -/dts-v1/; -/plugin/; - -#include -#include -#include -#include -#include -#define AT91_PINCTRL_OUT_INIT_0 (AT91_PINCTRL_OUTPUT|AT91_PINCTRL_OUTPUT_VAL(0)) -#define AT91_PINCTRL_OUT_INIT_1 (AT91_PINCTRL_OUTPUT|AT91_PINCTRL_OUTPUT_VAL(1)) - -/ { - compatible = "atmel,at91sam9g25ek", "atmel,at91sam9x5ek", "atmel,at91sam9x5", "atmel,at91sam9"; - fragment@0 { - target-path = "/ahb/apb/pinctrl@fffff400"; - __overlay__ { - mts_io { - radio_reset { - atmel,pins = ; - label = "radio-reset"; - alias = "radio-power"; - }; /* radio */ - device_reset { - atmel,pins = ; - label = "reset"; - active-low; - }; - eth_reset { - atmel,pins = ; - label = "eth-reset"; - }; /* eth */ - ls_led { - atmel,pins = ; - label = "led-ls"; - active_low; - }; - status_led { - atmel,pins = ; - label = "led-status"; - active_low; - }; - led5 { - atmel,pins = ; - label = "led-cd"; - alias = "led-a"; - active_low; - }; - led1 { - atmel,pins = ; - label = "led-sig1"; - alias = "led-b"; - active_low; - }; - }; /* mtsio */ - }; /* overlay */ - }; /* fragment@0 */ -}; diff --git a/mtcdt/ap1-gpiob-0.0.dtso b/mtcdt/ap1-gpiob-0.0.dtso new file mode 100644 index 0000000..3820acc --- /dev/null +++ b/mtcdt/ap1-gpiob-0.0.dtso @@ -0,0 +1,43 @@ +/* + * DTS overlay for MTCDT 0.0 hardware version. + */ + +/dts-v1/; + +/* + * Location(s): + * Put: MTCDT/0.0/ap1-gpiob.dtbo + */ + +#include +#include +#include +#include +#include +#define AT91_PINCTRL_OUT_INIT_0 (AT91_PINCTRL_OUTPUT|AT91_PINCTRL_OUTPUT_VAL(0)) +#define AT91_PINCTRL_OUT_INIT_1 (AT91_PINCTRL_OUTPUT|AT91_PINCTRL_OUTPUT_VAL(1)) + + +/ { + compatible = "ti,am437x-gp-evm", "ti,am4372", "ti,am43"; + fragment@0 { + target-path = "/apb/spi@f0000000 "; + __overlay__ { + ap1-adc@0 { + compatible = "mts-io-ap1-adc"; + spi-max-frequency = <0x1312d00>; + reg = <0x0>; + }; /*ap1-adc*/ + ap1-dout@1 { + compatible = "mts-io-ap1-dout"; + spi-max-frequency = <0xf4240>; + reg = <0x1>; + }; /*ap1-dout*/ + ap1-spi@2 { + compatible = "mts,mtac"; + spi-max-frequency = <0x1e8480>; + reg = <0x2>; + }; /*ap1-spi*/ + }; /*overlay*/ + }; /*fragment@0*/ +}; diff --git a/mtcdt/ap1-xdot-0.0.dtso b/mtcdt/ap1-xdot-0.0.dtso deleted file mode 100644 index d127e60..0000000 --- a/mtcdt/ap1-xdot-0.0.dtso +++ /dev/null @@ -1,35 +0,0 @@ -/* - * DTS overlay for MTCDT 0.0 hardware version. - */ -/dts-v1/; -/plugin/; - -/* - * Location(s): - * Put: MTCDT/0.0/ap1-xdot.dtbo - */ - -#include -#include -#include -#include -#include -#define AT91_PINCTRL_OUT_INIT_0 (AT91_PINCTRL_OUTPUT|AT91_PINCTRL_OUTPUT_VAL(0)) -#define AT91_PINCTRL_OUT_INIT_1 (AT91_PINCTRL_OUTPUT|AT91_PINCTRL_OUTPUT_VAL(1)) - -/ { - compatible = "atmel,at91sam9g25ek", "atmel,at91sam9x5ek", "atmel,at91sam9x5", "atmel,at91sam9"; - fragment@0 { - target-path = "/ahb/apb/pinctrl@fffff400"; - __overlay__ { - mtac_xdot { - ap1 { - reset { - atmel,pins = ; - label = "ap1-reset"; - }; /* Reset */ - }; /* ap1 */ - }; /* mtac_xdot */ - }; /* overlay */ - }; /* fragment@0 */ -}; diff --git a/mtcdt/ap2-gpiob-0.0.dtso b/mtcdt/ap2-gpiob-0.0.dtso new file mode 100644 index 0000000..57e2ef9 --- /dev/null +++ b/mtcdt/ap2-gpiob-0.0.dtso @@ -0,0 +1,43 @@ +/* + * DTS overlay for MTCDT 0.0 hardware version. + */ + +/dts-v1/; + +/* + * Location(s): + * Put: MTCDT/0.0/ap2-gpiob.dtbo + */ + +#include +#include +#include +#include +#include +#define AT91_PINCTRL_OUT_INIT_0 (AT91_PINCTRL_OUTPUT|AT91_PINCTRL_OUTPUT_VAL(0)) +#define AT91_PINCTRL_OUT_INIT_1 (AT91_PINCTRL_OUTPUT|AT91_PINCTRL_OUTPUT_VAL(1)) + + +/ { + compatible = "ti,am437x-gp-evm", "ti,am4372", "ti,am43"; + fragment@0 { + target-path = "/apb/spi@f0004000"; + __overlay__ { + ap2-adc@0 { + compatible = "mts-io-ap2-adc"; + spi-max-frequency = <0x1312d00>; + reg = <0x0>; + }; /*ap1-adc*/ + ap2-dout@1 { + compatible = "mts-io-ap2-dout"; + spi-max-frequency = <0xf4240>; + reg = <0x1>; + }; /*ap1-dout*/ + ap2-spi@2 { + compatible = "mts,mtac"; + spi-max-frequency = <0x1e8480>; + reg = <0x2>; + }; /*ap2-spi*/ + }; /*overlay*/ + }; /*fragment@0*/ +}; diff --git a/mtcdt/ap2-xdot-0.0.dtso b/mtcdt/ap2-xdot-0.0.dtso deleted file mode 100644 index 0e53309..0000000 --- a/mtcdt/ap2-xdot-0.0.dtso +++ /dev/null @@ -1,36 +0,0 @@ -/* - * DTS overlay for MTCDT 0.0 hardware version. - */ - -/* - * Location(s): - * Put: MTCDT/0.0/ap2-xdot.dtbo - */ - -/dts-v1/; -/plugin/; - -#include -#include -#include -#include -#include -#define AT91_PINCTRL_OUT_INIT_0 (AT91_PINCTRL_OUTPUT|AT91_PINCTRL_OUTPUT_VAL(0)) -#define AT91_PINCTRL_OUT_INIT_1 (AT91_PINCTRL_OUTPUT|AT91_PINCTRL_OUTPUT_VAL(1)) - -/ { - compatible = "atmel,at91sam9g25ek", "atmel,at91sam9x5ek", "atmel,at91sam9x5", "atmel,at91sam9"; - fragment@0 { - target-path = "/ahb/apb/pinctrl@fffff400"; - __overlay__ { - mtac_xdot { - ap2 { - reset { - atmel,pins = ; - label = "ap2-reset"; - }; /* Reset */ - }; /* ap2 */ - }; /* mtac_xdot */ - }; /* overlay */ - }; /* fragment@0 */ -}; diff --git a/mtcdt/mtcdt-0.0.dtso b/mtcdt/mtcdt-0.0.dtso deleted file mode 100644 index e88d0d2..0000000 --- a/mtcdt/mtcdt-0.0.dtso +++ /dev/null @@ -1,66 +0,0 @@ -/* - * DTS overlay for MTCDT 0.0 hardware version. - */ - -/* - * Location(s): - * Put: MTCDT/0.0/mtcdt.dtbo - */ - -/dts-v1/; -/plugin/; - -#include -#include -#include -#include -#include -#define AT91_PINCTRL_OUT_INIT_0 (AT91_PINCTRL_OUTPUT|AT91_PINCTRL_OUTPUT_VAL(0)) -#define AT91_PINCTRL_OUT_INIT_1 (AT91_PINCTRL_OUTPUT|AT91_PINCTRL_OUTPUT_VAL(1)) - -/ { - compatible = "atmel,at91sam9g25ek", "atmel,at91sam9x5ek", "atmel,at91sam9x5", "atmel,at91sam9"; - fragment@0 { - target-path = "/ahb/apb/pinctrl@fffff400"; - __overlay__ { - mts_io { - radio_reset { - atmel,pins = ; - label = "radio-reset"; - alias = "radio-power"; - }; /* radio */ - device_reset { - atmel,pins = ; - label = "reset"; - active-low; - }; - eth_reset { - atmel,pins = ; - label = "eth-reset"; - }; /* eth */ - ls_led { - atmel,pins = ; - label = "led-ls"; - active_low; - }; - status_led { - atmel,pins = ; - label = "led-status"; - active_low; - }; - led5 { - atmel,pins = ; - label = "led-cd"; - alias = "led-a"; - active_low; - }; - led1 { - atmel,pins = ; - label = "led-sig1"; - alias = "led-b"; - active_low; - }; - }; /* mtsio */ - }; /* overlay */ - }; /* fragment@0 */ -}; diff --git a/mtcdt/mtcdt-gpios.0.0.dtso b/mtcdt/mtcdt-gpios.0.0.dtso deleted file mode 100644 index 6234b30..0000000 --- a/mtcdt/mtcdt-gpios.0.0.dtso +++ /dev/null @@ -1,66 +0,0 @@ -/* - * DTS overlay for MTCDT 0.0 hardware version. - * Uses [name]-gpios from: - * https://www.kernel.org/doc/Documentation/devicetree/bindings/gpio/gpio.txt - */ - -/* - * Location(s): - * Put: MTCDT/0.0/gpios.dtbo - */ - -/dts-v1/; -/plugin/; - -#include "at91sam9g25.dtsi" -#include "at91sam9x5ek.dtsi" - -/ { - compatible = "atmel,at91sam9g25ek", "atmel,at91sam9x5ek", "atmel,at91sam9x5", "atmel,at91sam9"; - fragment@0 { - target-path = "/"; - __overlay__ { - mts-io { - compatible = "mts,mts-io"; - radio-reset { - radio-reset-gpios = <&pioC 3 GPIO_ACTIVE_HIGH>; - gpiof_out_init_high; - line-name = "radio-reset"; - alias = "radio-power"; - }; /* radio */ - reset { - reset-gpios = <&pioC 2 GPIO_ACTIVE_LOW>; - gpiof_in; - line-name = "reset"; - }; - eth-reset { - eth-reset-gpios = <&pioC 4 GPIO_ACTIVE_HIGH>; - gpiof_out_init_high; - line-name = "eth-reset"; - }; /* eth */ - ls-led { - ls-led-gpios = <&pioA 14 GPIO_ACTIVE_LOW>; - gpiof_out_init_high; - line-name = "led-ls"; - }; - status-led { - status-led-gpios = <&pioA 24 GPIO_ACTIVE_LOW>; - gpiof_out_init_high; - line-name = "led-status"; - }; - led5 { - led5-gpios = <&pioA 25 GPIO_ACTIVE_LOW>; - gpiof_out_init_high; - line-name = "led-cd"; - alias = "led-a"; - }; - led1 { - led1-gpios = <&pioA 26 GPIO_ACTIVE_LOW>; - gpiof_out_init_high; - line-name = "led-sig1"; - alias = "led-b"; - }; - }; /* mtsio */ - }; /* overlay */ - }; /* fragment@0 */ -}; diff --git a/mtcpmhs/ap1-gpiob-0.0.dtso b/mtcpmhs/ap1-gpiob-0.0.dtso new file mode 100644 index 0000000..faf9f09 --- /dev/null +++ b/mtcpmhs/ap1-gpiob-0.0.dtso @@ -0,0 +1,39 @@ +/* + * DTS overlay for MTCPM 0.0 hardware version. + */ + +/dts-v1/; + +/* + * Location(s): + * Put: MTCDT3/0.0/ap1-gpiob.dtbo + */ + +#include "am4372.dtsi" +#include +#include +#include + +/ { + compatible = "ti,am437x-gp-evm", "ti,am4372", "ti,am43"; + fragment@0 { + target-path = "/ocp@44000000/spi@48030000"; + __overlay__ { + ap1-adc@0 { + compatible = "mts-io-ap1-adc"; + spi-max-frequency = <0x1312d00>; + reg = <0x0>; + }; /*ap1-adc*/ + ap1-dout@1 { + compatible = "mts-io-ap1-dout"; + spi-max-frequency = <0xf4240>; + reg = <0x1>; + }; /*ap1-dout*/ + ap1-spi@2 { + compatible = "mts,mtac"; + spi-max-frequency = <0x1e8480>; + reg = <0x2>; + }; /*ap1-spi*/ + }; /*overlay*/ + }; /*fragment@0*/ +}; diff --git a/mtcpmhs/ap2-gpiob-0.0.dtso b/mtcpmhs/ap2-gpiob-0.0.dtso new file mode 100644 index 0000000..e1fdef2 --- /dev/null +++ b/mtcpmhs/ap2-gpiob-0.0.dtso @@ -0,0 +1,39 @@ +/* + * DTS overlay for MTCPM 0.0 hardware version. + */ + +/dts-v1/; + +/* + * Location(s): + * Put: MTCDT3/0.0/ap2-gpiob.dtbo + */ + +#include "am4372.dtsi" +#include +#include +#include + +/ { + compatible = "ti,am437x-gp-evm", "ti,am4372", "ti,am43"; + fragment@0 { + target-path = "/ocp@44000000/spi@481a2000"; + __overlay__ { + ap2-adc@0 { + compatible = "mts-io-ap2-adc"; + spi-max-frequency = <0x1312d00>; + reg = <0x0>; + }; /*ap1-adc*/ + ap2-dout@1 { + compatible = "mts-io-ap2-dout"; + spi-max-frequency = <0xf4240>; + reg = <0x1>; + }; /*ap1-dout*/ + ap2-spi@2 { + compatible = "mts,mtac"; + spi-max-frequency = <0x1e8480>; + reg = <0x2>; + }; /*ap2-spi*/ + }; /*overlay*/ + }; /*fragment@0*/ +}; -- cgit v1.2.3