diff options
Diffstat (limited to 'kernels/linux-libre-lts-knock/0008-USB-armory-support.patch')
-rw-r--r-- | kernels/linux-libre-lts-knock/0008-USB-armory-support.patch | 200 |
1 files changed, 164 insertions, 36 deletions
diff --git a/kernels/linux-libre-lts-knock/0008-USB-armory-support.patch b/kernels/linux-libre-lts-knock/0008-USB-armory-support.patch index eccf0bb62..14e8e2530 100644 --- a/kernels/linux-libre-lts-knock/0008-USB-armory-support.patch +++ b/kernels/linux-libre-lts-knock/0008-USB-armory-support.patch @@ -1,40 +1,46 @@ -From 163421a4fef11bea6cf4bdb4ad9de67fb340bb90 Mon Sep 17 00:00:00 2001 +From 0bef4c3483f1a30f027ae375e1c04a2e6be91150 Mon Sep 17 00:00:00 2001 From: Kevin Mihelich <kevin@archlinuxarm.org> -Date: Sat, 7 Mar 2015 16:51:15 -0700 -Subject: [PATCH 8/8] USB armory support +Date: Sat, 7 Feb 2015 12:32:27 +0100 +Subject: [PATCH 8/9] USB armory support --- - arch/arm/boot/dts/Makefile | 3 + - arch/arm/boot/dts/imx53-usbarmory-common.dtsi | 209 ++++++++++++++++++++++++++ - arch/arm/boot/dts/imx53-usbarmory-gpio.dts | 26 ++++ - arch/arm/boot/dts/imx53-usbarmory-host.dts | 18 +++ - arch/arm/boot/dts/imx53-usbarmory.dts | 18 +++ - 5 files changed, 274 insertions(+) + arch/arm/boot/dts/Makefile | 5 + + arch/arm/boot/dts/imx53-usbarmory-common.dtsi | 241 ++++++++++++++++++++++++++ + arch/arm/boot/dts/imx53-usbarmory-gpio.dts | 26 +++ + arch/arm/boot/dts/imx53-usbarmory-host.dts | 18 ++ + arch/arm/boot/dts/imx53-usbarmory-i2c.dts | 32 ++++ + arch/arm/boot/dts/imx53-usbarmory-spi.dts | 45 +++++ + arch/arm/boot/dts/imx53-usbarmory.dts | 18 ++ + 7 files changed, 385 insertions(+) create mode 100644 arch/arm/boot/dts/imx53-usbarmory-common.dtsi create mode 100644 arch/arm/boot/dts/imx53-usbarmory-gpio.dts create mode 100644 arch/arm/boot/dts/imx53-usbarmory-host.dts + create mode 100644 arch/arm/boot/dts/imx53-usbarmory-i2c.dts + create mode 100644 arch/arm/boot/dts/imx53-usbarmory-spi.dts create mode 100644 arch/arm/boot/dts/imx53-usbarmory.dts diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile -index 2373ab3..27728dd 100644 +index 4a41a60..a2df2c2 100644 --- a/arch/arm/boot/dts/Makefile +++ b/arch/arm/boot/dts/Makefile -@@ -252,6 +252,9 @@ dtb-$(CONFIG_SOC_IMX53) += \ +@@ -268,6 +268,11 @@ dtb-$(CONFIG_SOC_IMX53) += \ imx53-smd.dtb \ imx53-tx53-x03x.dtb \ imx53-tx53-x13x.dtb \ + imx53-usbarmory.dtb \ + imx53-usbarmory-gpio.dtb \ + imx53-usbarmory-host.dtb \ ++ imx53-usbarmory-i2c.dtb \ ++ imx53-usbarmory-spi.dtb \ imx53-voipac-bsb.dtb dtb-$(CONFIG_SOC_IMX6Q) += \ - imx6dl-aristainetos_4.dtb \ + imx6dl-apf6dev.dtb \ diff --git a/arch/arm/boot/dts/imx53-usbarmory-common.dtsi b/arch/arm/boot/dts/imx53-usbarmory-common.dtsi new file mode 100644 -index 0000000..c7cbd84 +index 0000000..b73c399 --- /dev/null +++ b/arch/arm/boot/dts/imx53-usbarmory-common.dtsi -@@ -0,0 +1,209 @@ +@@ -0,0 +1,241 @@ +/* + * USB armory MkI device tree include file + * http://inversepath.com/usbarmory @@ -112,16 +118,6 @@ index 0000000..c7cbd84 + pinctrl-names = "default"; + + imx53-usbarmory { -+ pinctrl_pinheader: pinheadergrp { -+ fsl,pins = < -+ MX53_PAD_CSI0_DAT8__GPIO5_26 0xc0 -+ MX53_PAD_CSI0_DAT9__GPIO5_27 0xc0 -+ MX53_PAD_CSI0_DAT10__GPIO5_28 0xc0 -+ MX53_PAD_CSI0_DAT11__GPIO5_29 0xc0 -+ MX53_PAD_CSI0_DAT12__GPIO5_30 0xc0 -+ >; -+ }; -+ + led_pin_gpio4_27: led_gpio4_27@0 { + fsl,pins = < + MX53_PAD_DISP0_DAT6__GPIO4_27 0x80000000 @@ -139,26 +135,67 @@ index 0000000..c7cbd84 + >; + }; + -+ pinctrl_i2c1: i2c1grp { ++ pinctrl_i2c1_pmic: i2c1grp_pmic { + fsl,pins = < -+ MX53_PAD_CSI0_DAT8__I2C1_SDA 0xc0000000 -+ MX53_PAD_CSI0_DAT9__I2C1_SCL 0xc0000000 ++ MX53_PAD_EIM_D21__I2C1_SCL 0xc0000000 ++ MX53_PAD_EIM_D28__I2C1_SDA 0xc0000000 + >; + }; + ++ /* ++ UART mode pin header configration: ++ pin number: 1 2 3 4 5 6 7 ++ function: GND 5V ? ? TX RX ? ++ */ + pinctrl_uart1: uart1grp { + fsl,pins = < + MX53_PAD_CSI0_DAT10__UART1_TXD_MUX 0x1e4 + MX53_PAD_CSI0_DAT11__UART1_RXD_MUX 0x1e4 + >; + }; ++ ++ /* ++ GPIO mode pin header configuration: ++ 1 2 3 4 5 6 7 ++ GND 5V GPIO5[26] GPIO5[27] GPIO5[28] GPIO5[29] GPIO5[30] ++ */ + pinctrl_gpio5: gpio5grp { + fsl,pins = < -+ MX53_PAD_CSI0_DAT8__GPIO5_26 0xc0 -+ MX53_PAD_CSI0_DAT9__GPIO5_27 0xc0 -+ MX53_PAD_CSI0_DAT10__GPIO5_28 0xc0 -+ MX53_PAD_CSI0_DAT11__GPIO5_29 0xc0 -+ MX53_PAD_CSI0_DAT12__GPIO5_30 0xc0 ++ MX53_PAD_CSI0_DAT8__GPIO5_26 0xc0 ++ MX53_PAD_CSI0_DAT9__GPIO5_27 0xc0 ++ MX53_PAD_CSI0_DAT10__GPIO5_28 0xc0 ++ MX53_PAD_CSI0_DAT11__GPIO5_29 0xc0 ++ MX53_PAD_CSI0_DAT12__GPIO5_30 0xc0 ++ >; ++ }; ++ ++ /* ++ SPI mode pin header configuration: ++ 1 2 3 4 5 6 7 ++ GND 5V SCLK MOSI MISO /SS0 /SS1 ++ */ ++ pinctrl_ecspi2: ecspi2grp { ++ fsl,pins = < ++ MX53_PAD_CSI0_DAT8__ECSPI2_SCLK 0x80000000 ++ MX53_PAD_CSI0_DAT9__ECSPI2_MOSI 0x80000000 ++ MX53_PAD_CSI0_DAT10__ECSPI2_MISO 0x80000000 ++ MX53_PAD_CSI0_DAT11__GPIO5_29 0x80000000 ++ MX53_PAD_CSI0_DAT12__GPIO5_30 0x80000000 ++ >; ++ }; ++ ++ /* ++ I2C mode pin header configuration: ++ 1 2 3 4 5 6 7 ++ GND 5V SDA SCL GPIO5[28] GPIO5[29] GPIO5[30] ++ */ ++ pinctrl_i2c1_pinheader: i2c1grp_pinheader { ++ fsl,pins = < ++ MX53_PAD_CSI0_DAT8__I2C1_SDA 0xc0000000 ++ MX53_PAD_CSI0_DAT9__I2C1_SCL 0xc0000000 ++ MX53_PAD_CSI0_DAT10__GPIO5_28 0x80000000 ++ MX53_PAD_CSI0_DAT11__GPIO5_29 0x80000000 ++ MX53_PAD_CSI0_DAT12__GPIO5_30 0x80000000 + >; + }; + }; @@ -175,10 +212,11 @@ index 0000000..c7cbd84 +}; + +&i2c1 { ++ pinctrl-0 = <&pinctrl_i2c1_pmic>; ++ status = "okay"; + ltc3589: pmic@34 { + compatible = "lltc,ltc3589-2"; + reg = <0x34>; -+ + regulators { + sw1_reg: sw1 { + regulator-min-microvolt = <591930>; @@ -246,7 +284,7 @@ index 0000000..c7cbd84 +}; diff --git a/arch/arm/boot/dts/imx53-usbarmory-gpio.dts b/arch/arm/boot/dts/imx53-usbarmory-gpio.dts new file mode 100644 -index 0000000..bf85ffa +index 0000000..a27c759 --- /dev/null +++ b/arch/arm/boot/dts/imx53-usbarmory-gpio.dts @@ -0,0 +1,26 @@ @@ -270,7 +308,7 @@ index 0000000..bf85ffa +}; + +&iomuxc { -+ pinctrl-0 = <&pinctrl_pinheader>; ++ pinctrl-0 = <&pinctrl_gpio5>; +}; + +&uart1 { @@ -300,6 +338,95 @@ index 0000000..ea2ea45 + dr_mode = "host"; + status = "okay"; +}; +diff --git a/arch/arm/boot/dts/imx53-usbarmory-i2c.dts b/arch/arm/boot/dts/imx53-usbarmory-i2c.dts +new file mode 100644 +index 0000000..c66bbb5 +--- /dev/null ++++ b/arch/arm/boot/dts/imx53-usbarmory-i2c.dts +@@ -0,0 +1,32 @@ ++/* ++ * USB armory MkI device mode device tree file ++ * http://inversepath.com/usbarmory ++ * ++ * Copyright (C) 2015, Inverse Path ++ * Andrej Rosano <andrej@inversepath.com> ++ * ++ * Licensed under GPLv2 ++ */ ++ ++/dts-v1/; ++ ++#include "imx53-usbarmory-common.dtsi" ++ ++&usbotg { ++ dr_mode = "peripheral"; ++ status = "okay"; ++}; ++ ++&uart1 { ++ status = "disabled"; ++}; ++ ++&iomuxc { ++ pinctrl-0 = <&pinctrl_i2c1_pinheader>; ++}; ++ ++&i2c1 { ++ ltc3589: pmic@34 { ++ status = "disabled"; ++ }; ++}; +diff --git a/arch/arm/boot/dts/imx53-usbarmory-spi.dts b/arch/arm/boot/dts/imx53-usbarmory-spi.dts +new file mode 100644 +index 0000000..414d641 +--- /dev/null ++++ b/arch/arm/boot/dts/imx53-usbarmory-spi.dts +@@ -0,0 +1,45 @@ ++/* ++ * USB armory MkI device mode device tree file ++ * http://inversepath.com/usbarmory ++ * ++ * Copyright (C) 2015, Inverse Path ++ * Andrej Rosano <andrej@inversepath.com> ++ * ++ * Licensed under GPLv2 ++ */ ++ ++/dts-v1/; ++ ++#include "imx53-usbarmory-common.dtsi" ++ ++&usbotg { ++ dr_mode = "peripheral"; ++ status = "okay"; ++}; ++ ++&uart1 { ++ status = "disabled"; ++}; ++ ++&iomuxc { ++ pinctrl-0 = <&pinctrl_ecspi2>; ++}; ++ ++&ecspi2 { ++ fsl,spi-num-chipselects = <2>; ++ cs-gpios = <&gpio5 29 0>, <&gpio5 30 0>; ++ status = "okay"; ++ ++ flash: m25p40@0 { ++ #address-cells = <1>; ++ #size-cells = <1>; ++ compatible = "st,m25p40", "st,m25p"; ++ spi-max-frequency = <20000000>; ++ reg = <0>; ++ ++ partition@0 { ++ label = "test-partition"; ++ reg = <0x0 0x80000>; ++ }; ++ }; ++}; diff --git a/arch/arm/boot/dts/imx53-usbarmory.dts b/arch/arm/boot/dts/imx53-usbarmory.dts new file mode 100644 index 0000000..902a73b @@ -325,4 +452,5 @@ index 0000000..902a73b + status = "okay"; +}; -- -2.4.4 +2.6.4 + |