alarm/uboot-usbarmory-mkii to 2019.07-2

This commit is contained in:
Kevin Mihelich 2019-09-26 00:51:03 +00:00
parent 5022cba674
commit 4d88078ca9
3 changed files with 50 additions and 48 deletions

View file

@ -1,4 +1,4 @@
From 21643481b395ecfa3fbe1d742c4aae4f621ebff9 Mon Sep 17 00:00:00 2001 From dd52cf8ec4cf724377cc0b3c6960db0533a7d33d Mon Sep 17 00:00:00 2001
From: Andrej Rosano <andrej.rosano@f-secure.com> From: Andrej Rosano <andrej.rosano@f-secure.com>
Date: Mon, 15 Jul 2019 16:13:57 +0200 Date: Mon, 15 Jul 2019 16:13:57 +0200
Subject: [PATCH 1/2] ARM: mx6: add support for USB armory Mk II board Subject: [PATCH 1/2] ARM: mx6: add support for USB armory Mk II board
@ -11,17 +11,17 @@ http://inversepath.com/usbarmory
Signed-off-by: Andrej Rosano <andrej.rosano@f-secure.com> Signed-off-by: Andrej Rosano <andrej.rosano@f-secure.com>
--- ---
arch/arm/dts/Makefile | 3 +- arch/arm/dts/Makefile | 3 +-
arch/arm/dts/imx6ull-usbarmory.dts | 237 ++++++++++++++ arch/arm/dts/imx6ull-usbarmory.dts | 208 ++++++++++++
arch/arm/mach-imx/mx6/Kconfig | 8 + arch/arm/mach-imx/mx6/Kconfig | 8 +
board/inversepath/usbarmory-mark-two/Kconfig | 67 ++++ board/inversepath/usbarmory-mark-two/Kconfig | 67 ++++
.../usbarmory-mark-two/MAINTAINERS | 6 + .../usbarmory-mark-two/MAINTAINERS | 6 +
board/inversepath/usbarmory-mark-two/Makefile | 10 + board/inversepath/usbarmory-mark-two/Makefile | 10 +
.../usbarmory-mark-two/imximage-1gb.cfg | 90 ++++++ .../usbarmory-mark-two/imximage-1gb.cfg | 90 +++++
.../usbarmory-mark-two/imximage-512mb.cfg | 92 ++++++ .../usbarmory-mark-two/imximage-512mb.cfg | 92 +++++
.../usbarmory-mark-two/usbarmory-mark-two.c | 290 ++++++++++++++++++ .../usbarmory-mark-two/usbarmory-mark-two.c | 321 ++++++++++++++++++
configs/usbarmory-mark-two_defconfig | 64 ++++ configs/usbarmory-mark-two_defconfig | 64 ++++
include/configs/usbarmory-mark-two.h | 242 +++++++++++++++ include/configs/usbarmory-mark-two.h | 242 +++++++++++++
11 files changed, 1108 insertions(+), 1 deletion(-) 11 files changed, 1110 insertions(+), 1 deletion(-)
create mode 100644 arch/arm/dts/imx6ull-usbarmory.dts create mode 100644 arch/arm/dts/imx6ull-usbarmory.dts
create mode 100644 board/inversepath/usbarmory-mark-two/Kconfig create mode 100644 board/inversepath/usbarmory-mark-two/Kconfig
create mode 100644 board/inversepath/usbarmory-mark-two/MAINTAINERS create mode 100644 board/inversepath/usbarmory-mark-two/MAINTAINERS
@ -48,10 +48,10 @@ index 20dbc2ff84..3efa735a48 100644
imx6-apalis.dtb \ imx6-apalis.dtb \
diff --git a/arch/arm/dts/imx6ull-usbarmory.dts b/arch/arm/dts/imx6ull-usbarmory.dts diff --git a/arch/arm/dts/imx6ull-usbarmory.dts b/arch/arm/dts/imx6ull-usbarmory.dts
new file mode 100644 new file mode 100644
index 0000000000..d3f0482ff5 index 0000000000..37b8d00a2b
--- /dev/null --- /dev/null
+++ b/arch/arm/dts/imx6ull-usbarmory.dts +++ b/arch/arm/dts/imx6ull-usbarmory.dts
@@ -0,0 +1,237 @@ @@ -0,0 +1,208 @@
+/* +/*
+ * USB armory Mk II device tree file + * USB armory Mk II device tree file
+ * https://inversepath.com/usbarmory + * https://inversepath.com/usbarmory
@ -190,7 +190,6 @@ index 0000000000..d3f0482ff5
+ +
+&usdhc1 { +&usdhc1 {
+ pinctrl-names = "default"; + pinctrl-names = "default";
+ pinctrl-0 = <&pinctrl_usdhc1>;
+ no-1-8-v; + no-1-8-v;
+ keep-power-in-suspend; + keep-power-in-suspend;
+ wakeup-source; + wakeup-source;
@ -200,7 +199,6 @@ index 0000000000..d3f0482ff5
+ +
+&usdhc2 { +&usdhc2 {
+ pinctrl-names = "default"; + pinctrl-names = "default";
+ pinctrl-0 = <&pinctrl_usdhc2>;
+ non-removable; + non-removable;
+ status = "okay"; + status = "okay";
+}; +};
@ -247,33 +245,6 @@ index 0000000000..d3f0482ff5
+ MX6UL_PAD_CSI_DATA07__GPIO4_IO28 0x1f020 + MX6UL_PAD_CSI_DATA07__GPIO4_IO28 0x1f020
+ >; + >;
+ }; + };
+
+ pinctrl_usdhc1: usdhc1grp {
+ fsl,pins = <
+ MX6UL_PAD_SD1_CMD__USDHC1_CMD 0x1f019
+ MX6UL_PAD_SD1_CLK__USDHC1_CLK 0x1f019
+ MX6UL_PAD_SD1_DATA0__USDHC1_DATA0 0x1f019
+ MX6UL_PAD_SD1_DATA1__USDHC1_DATA1 0x1f019
+ MX6UL_PAD_SD1_DATA2__USDHC1_DATA2 0x1f019
+ MX6UL_PAD_SD1_DATA3__USDHC1_DATA3 0x1f019
+ MX6UL_PAD_UART1_RTS_B__USDHC1_CD_B 0x1f019
+ >;
+ };
+
+ pinctrl_usdhc2: usdhc2grp {
+ fsl,pins = <
+ MX6UL_PAD_NAND_RE_B__USDHC2_CLK 0x10071
+ MX6UL_PAD_NAND_WE_B__USDHC2_CMD 0x17059
+ MX6UL_PAD_NAND_DATA00__USDHC2_DATA0 0x17059
+ MX6UL_PAD_NAND_DATA01__USDHC2_DATA1 0x17059
+ MX6UL_PAD_NAND_DATA02__USDHC2_DATA2 0x17059
+ MX6UL_PAD_NAND_DATA03__USDHC2_DATA3 0x17059
+ MX6UL_PAD_NAND_DATA04__USDHC2_DATA4 0x17059
+ MX6UL_PAD_NAND_DATA05__USDHC2_DATA5 0x17059
+ MX6UL_PAD_NAND_DATA06__USDHC2_DATA6 0x17059
+ MX6UL_PAD_NAND_DATA07__USDHC2_DATA7 0x17059
+ >;
+ };
+}; +};
+ +
+&usbotg1 { +&usbotg1 {
@ -612,10 +583,10 @@ index 0000000000..953309f8f9
+DATA 4 0x021B001C 0x00000000 /* MMDC_MDSCR */ +DATA 4 0x021B001C 0x00000000 /* MMDC_MDSCR */
diff --git a/board/inversepath/usbarmory-mark-two/usbarmory-mark-two.c b/board/inversepath/usbarmory-mark-two/usbarmory-mark-two.c diff --git a/board/inversepath/usbarmory-mark-two/usbarmory-mark-two.c b/board/inversepath/usbarmory-mark-two/usbarmory-mark-two.c
new file mode 100644 new file mode 100644
index 0000000000..c6d15fff05 index 0000000000..bd540dd613
--- /dev/null --- /dev/null
+++ b/board/inversepath/usbarmory-mark-two/usbarmory-mark-two.c +++ b/board/inversepath/usbarmory-mark-two/usbarmory-mark-two.c
@@ -0,0 +1,290 @@ @@ -0,0 +1,321 @@
+// SPDX-License-Identifier: GPL-2.0+ +// SPDX-License-Identifier: GPL-2.0+
+/* +/*
+ * USB armory Mk II board initialization + * USB armory Mk II board initialization
@ -654,6 +625,9 @@ index 0000000000..c6d15fff05
+#define WEAK_PULLUP (PAD_CTL_PUS_100K_UP || \ +#define WEAK_PULLUP (PAD_CTL_PUS_100K_UP || \
+ PAD_CTL_SPEED_MED | PAD_CTL_DSE_40ohm | PAD_CTL_HYS || \ + PAD_CTL_SPEED_MED | PAD_CTL_DSE_40ohm | PAD_CTL_HYS || \
+ PAD_CTL_SRE_SLOW) + PAD_CTL_SRE_SLOW)
+#define USDHC_PAD_CTRL (PAD_CTL_PKE | PAD_CTL_PUE | \
+ PAD_CTL_PUS_22K_UP | PAD_CTL_SPEED_LOW | \
+ PAD_CTL_DSE_80ohm | PAD_CTL_SRE_FAST | PAD_CTL_HYS)
+ +
+static void setup_iomux_uart(void) +static void setup_iomux_uart(void)
+{ +{
@ -684,6 +658,33 @@ index 0000000000..c6d15fff05
+ imx_iomux_v3_setup_multiple_pads(pads, ARRAY_SIZE(pads)); + imx_iomux_v3_setup_multiple_pads(pads, ARRAY_SIZE(pads));
+} +}
+ +
+static void setup_iomux_mmc(void)
+{
+ static const iomux_v3_cfg_t pads[] = {
+ /* microSD */
+ MX6_PAD_SD1_CLK__USDHC1_CLK | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_SD1_CMD__USDHC1_CMD | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_SD1_DATA0__USDHC1_DATA0 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_SD1_DATA1__USDHC1_DATA1 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_SD1_DATA2__USDHC1_DATA2 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_SD1_DATA3__USDHC1_DATA3 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_UART1_RTS_B__USDHC1_CD_B | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ /* eMMC */
+ MX6_PAD_NAND_RE_B__USDHC2_CLK | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_NAND_WE_B__USDHC2_CMD | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_NAND_DATA00__USDHC2_DATA0 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_NAND_DATA01__USDHC2_DATA1 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_NAND_DATA02__USDHC2_DATA2 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_NAND_DATA03__USDHC2_DATA3 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_NAND_DATA04__USDHC2_DATA4 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_NAND_DATA05__USDHC2_DATA5 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_NAND_DATA06__USDHC2_DATA6 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
+ MX6_PAD_NAND_DATA07__USDHC2_DATA7 | MUX_PAD_CTRL(USDHC_PAD_CTRL)
+ };
+
+ imx_iomux_v3_setup_multiple_pads(pads, ARRAY_SIZE(pads));
+}
+
+static void setup_iomux_misc(void) +static void setup_iomux_misc(void)
+{ +{
+ static const iomux_v3_cfg_t pads[] = { + static const iomux_v3_cfg_t pads[] = {
@ -857,6 +858,7 @@ index 0000000000..c6d15fff05
+ // the fsusb303_init() does not have effect. + // the fsusb303_init() does not have effect.
+ setup_iomux_i2c(); + setup_iomux_i2c();
+ setup_iomux_uart(); + setup_iomux_uart();
+ setup_iomux_mmc();
+ setup_iomux_unused_boot(); + setup_iomux_unused_boot();
+ setup_iomux_unused_nc(); + setup_iomux_unused_nc();
+ setup_iomux_misc(); + setup_iomux_misc();
@ -1225,5 +1227,5 @@ index 0000000000..647823ec86
+ +
+#endif /* __CONFIG_H */ +#endif /* __CONFIG_H */
-- --
2.22.0 2.23.0

View file

@ -1,4 +1,4 @@
From 76f9f8142a854b061c118c295a2b22e5ae4e51d1 Mon Sep 17 00:00:00 2001 From 0a6466284f8cd3a82ccce7bc03206ca0b36b8edd Mon Sep 17 00:00:00 2001
From: Kevin Mihelich <kevin@archlinuxarm.org> From: Kevin Mihelich <kevin@archlinuxarm.org>
Date: Sun, 11 Aug 2019 16:18:19 -0600 Date: Sun, 11 Aug 2019 16:18:19 -0600
Subject: [PATCH 2/2] arch linux arm modifications Subject: [PATCH 2/2] arch linux arm modifications
@ -19,5 +19,5 @@ index 40981a66da..31f51aca58 100644
+# Arch Linux ARM +# Arch Linux ARM
+CONFIG_IMAGE_FORMAT_LEGACY=y +CONFIG_IMAGE_FORMAT_LEGACY=y
-- --
2.22.0 2.23.0

View file

@ -1,12 +1,12 @@
# U-Boot: USB Armory MkII # U-Boot: USB armory Mk II
# Maintainer: Kevin Mihelich <kevin@archlinuxarm.org> # Maintainer: Kevin Mihelich <kevin@archlinuxarm.org>
buildarch=4 buildarch=4
pkgname=uboot-usbarmory-mkii pkgname=uboot-usbarmory-mkii
pkgver=2019.07 pkgver=2019.07
pkgrel=1 pkgrel=2
pkgdesc="U-Boot for USB Armory MkII" pkgdesc="U-Boot for USB armory Mk II"
arch=('armv7h') arch=('armv7h')
url="http://git.denx.de/u-boot.git/" url="http://git.denx.de/u-boot.git/"
license=('GPL') license=('GPL')
@ -19,8 +19,8 @@ source=("ftp://ftp.denx.de/pub/u-boot/u-boot-${pkgver}.tar.bz2"
'boot.txt' 'boot.txt'
'mkscr') 'mkscr')
md5sums=('73434338536c7500b4302bd0a02921ed' md5sums=('73434338536c7500b4302bd0a02921ed'
'229b644ebc7109c4ee697ea139b22b61' 'd573e51bad231edd3c2f80eaca11fded'
'8332464f088b427c082ac82143a8012f' 'e7187d62bff6509cdbeec6a9398072bc'
'9f0f7aa1a7c3ed679ae9d43516155bd8' '9f0f7aa1a7c3ed679ae9d43516155bd8'
'021623a04afd29ac3f368977140cfbfd') '021623a04afd29ac3f368977140cfbfd')