[OpenWrt-Devel] [PATCH v2] ipq40xx: add support for ASUS Lyra

2019-02-12 Thread Marius Genheimer
SoC:   Qualcomm IPQ4019 (Dakota) 717 MHz, 4 cores
RAM:   256 MiB (Nanya NT5CC128M16IP-DI)
FLASH: 128 MiB (Macronix NAND)
WiFi0: Qualcomm IPQ4019 b/g/n 2x2
WiFi1: Qualcomm IPQ4019 a/n/ac 2x2
WiFi2: Qualcomm Atheros QCA9886 a/n/ac
BT:Atheros AR3012
IN:WPS Button, Reset Button
OUT:   RGB-LED via TI LP5523 9-channel Controller
UART:  Front of Device - 115200 N-8
   Pinout 3.3v - RX - TX - GND (Square is VCC)

Installation:
1. Transfer OpenWRT-initramfs image to the device via SSH to /tmp.
Login credentials are identical to the Web UI.

2. Login to the device via SSH.

3. Flash the initramfs image using

> mtd-write -d linux -i openwrt-image-file

4. Power-cycle the device and wait for OpenWRT to boot.

5. From there flash the OpenWRT-sysupgrade image.

Ethernet-Ports: Although labeled identically, the port next to
the power socket is the LAN port and the other one is WAN. This
is the same behavior as in the stock firmware.

Signed-off-by: Marius Genheimer 
---
 package/firmware/ipq-wifi/Makefile |   3 +-
 package/firmware/ipq-wifi/board-map-ac2200.bin | Bin 0 -> 24324 bytes
 .../ipq40xx/base-files/etc/board.d/02_network  |   8 +
 .../etc/hotplug.d/firmware/11-ath10k-caldata   |   9 +
 .../lib/preinit/05_set_iface_mac_ipq40xx.sh|   5 +
 .../ipq40xx/base-files/lib/upgrade/platform.sh |   4 +
 target/linux/ipq40xx/config-4.14   |   1 +
 .../arch/arm/boot/dts/qcom-ipq4019-map-ac2200.dts  | 304 +
 .../arch/arm/boot/dts/qcom-ipq4019-map-ac2200.dts  | 304 +
 target/linux/ipq40xx/image/Makefile|   9 +
 .../patches-4.14/901-arm-boot-add-dts-files.patch  |   3 +-
 .../patches-4.19/901-arm-boot-add-dts-files.patch  |   3 +-
 12 files changed, 650 insertions(+), 3 deletions(-)
 create mode 100644 package/firmware/ipq-wifi/board-map-ac2200.bin
 create mode 100644 
target/linux/ipq40xx/files-4.14/arch/arm/boot/dts/qcom-ipq4019-map-ac2200.dts
 create mode 100644 
target/linux/ipq40xx/files-4.19/arch/arm/boot/dts/qcom-ipq4019-map-ac2200.dts

diff --git a/package/firmware/ipq-wifi/Makefile 
b/package/firmware/ipq-wifi/Makefile
index cf1ad042bf..7c9def8967 100644
--- a/package/firmware/ipq-wifi/Makefile
+++ b/package/firmware/ipq-wifi/Makefile
@@ -17,7 +17,7 @@ endef
 # Please send a mail with your device-specific board files upstream.
 # You can find instructions and examples on the linux-wireless wiki:
 # 
-ALLWIFIBOARDS:=engenius_eap1300 linksys_ea6350v3
+ALLWIFIBOARDS:=asus_map-ac2200 engenius_eap1300 linksys_ea6350v3
 ALLWIFIPACKAGES:=$(foreach BOARD,$(ALLWIFIBOARDS),ipq-wifi-$(BOARD))
 
 define Package/ipq-wifi-default
@@ -52,6 +52,7 @@ Don't install it for any other device!
 endef
 
 #$(eval $(call 
generate-ipq-wifi-package,,,))
+$(eval $(call 
generate-ipq-wifi-package,asus_map-ac2200,board-map-ac2200.bin,ASUS MAP-AC2200))
 $(eval $(call 
generate-ipq-wifi-package,engenius_eap1300,board-engenius_eap1300.bin,EnGenius 
EAP1300))
 $(eval $(call 
generate-ipq-wifi-package,linksys_ea6350v3,board-linksys_ea6350v3.bin,Linksys 
EA6350v3))
 
diff --git a/package/firmware/ipq-wifi/board-map-ac2200.bin 
b/package/firmware/ipq-wifi/board-map-ac2200.bin
new file mode 100644
index 
..372936010a4723ee0197dc56cbfd3a193e559552
GIT binary patch
literal 24324
zcmeHPeNak-f$|Vq#_}SHh=UL>2J)qF*bY=ny#pH1~^Bu7H`L7>iDn%Zh=dF6z`3y}w9AY!C+OCE1C;w!|6
z4#_g)hDOlH9Z#fVlE+kc4tui2_PEy_7?-$Wlan`;i4|
zZ}OE7T_~=LD-@{$l%I81zq|RUxO~kkAN5wXY&sTE6}abidr3|5tGrb24I`b!htrBf
zvwRhoE~=YT>ep2T6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tSsb`}_a++n>Jw{;yzL2{*eI|DS#u`=0cd
z$zr3(KF7!Z{R3%pCa|`6_mPoeF_FX(;o)nAz`4hrqlK?qYwC`RJ4dsHgDu{@g>FB=
zeV=%HbB%f^vrBojyn8AXm!ZGU+l1_SheED}$!AlzY8*6lXf&z}Y54GO3{Bc1RiczjI9$IK7KTjC
zG}>%!_UK2(HhqO=t7^URBmEgoS&Bj`0f&>?*C~e^x57kd^qR3E?(~gkY-YjK>WX`aB59U^t>L)vAmi7|v;mQWB(*qaPbD=&Lo`rT(OY
zD3q8(li{F#k2V7;+w})DTU3z{NQ<^Yl`a*HUNN

Re: [OpenWrt-Devel] [PATCH v2] ipq40xx: add support for ASUS Lyra

2019-02-12 Thread Christian Lamparter
On Tuesday, February 12, 2019 5:19:51 PM CET Marius Genheimer wrote:
> SoC:   Qualcomm IPQ4019 (Dakota) 717 MHz, 4 cores
> RAM:   256 MiB (Nanya NT5CC128M16IP-DI)
> FLASH: 128 MiB (Macronix NAND)
> WiFi0: Qualcomm IPQ4019 b/g/n 2x2
> WiFi1: Qualcomm IPQ4019 a/n/ac 2x2
> WiFi2: Qualcomm Atheros QCA9886 a/n/ac
> BT:Atheros AR3012
> IN:WPS Button, Reset Button
> OUT:   RGB-LED via TI LP5523 9-channel Controller
> UART:  Front of Device - 115200 N-8
>Pinout 3.3v - RX - TX - GND (Square is VCC)
> 
> Installation:
> 1. Transfer OpenWRT-initramfs image to the device via SSH to /tmp.
> Login credentials are identical to the Web UI.
> 
> 2. Login to the device via SSH.
> 
> 3. Flash the initramfs image using
> 
> > mtd-write -d linux -i openwrt-image-file
> 
> 4. Power-cycle the device and wait for OpenWRT to boot.
> 
> 5. From there flash the OpenWRT-sysupgrade image.
> 
> Ethernet-Ports: Although labeled identically, the port next to
> the power socket is the LAN port and the other one is WAN. This
> is the same behavior as in the stock firmware.
> 
> Signed-off-by: Marius Genheimer 
> ---
Thanks. I made some changes to the commit, please let me know 
if the QCA9886 still works as expected (I copied the board WA
from ath79 for the time being - but it would be nice to have
the boardData for the QCA9886 upstream as well - see below).

https://git.openwrt.org/?p=openwrt/staging/chunkeey.git;a=commit;h=0be33481fbb784958476cd3449a0c3bd306ac535

> +&wifi0{
> + status = "okay";
> + qcom,ath10k-calibration-variant = "ASUS-MAP-AC2200";
> +};
> +
> +&wifi1{
> + status = "okay";
> + qcom,ath10k-calibration-variant = "ASUS-MAP-AC2200";
> +};
> +
> +&pcie0 {
> + status = "okay";
> + perst-gpio = <&tlmm 38 GPIO_ACTIVE_LOW>;
> + wake-gpio = <&tlmm 50 GPIO_ACTIVE_LOW>;
> +
> + bridge@0,0 {
> + reg = <0x 0 0 0 0>;
> + #address-cells = <3>;
> + #size-cells = <2>;
> + ranges;
> +
> + wifi2: wifi@1,0 {
> + compatible = "qcom,ath10k";
> + status = "okay";
> + reg = <0x0001 0 0 0 0>;
> + qcom,ath10k-calibration-variant = "ASUS-MAP-AC2200";
> + };
> + };
> +};
> +
Since you added the "qcom,ath10k-calibration-variant" for the QCA9886, I looked
into the stock firmware and compared the custom boardData with what's upstream
in the ath10k-firmware board-2.bin repositories. And indeed, you probably want
to also upstream the boardData of the QCA9886(variant of the QCA9888). 

The process is the same as with the IPQ4019/QCA4019 boardData:


Best Regards,
Christian



___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel