<html><head><meta http-equiv="content-type" content="text/html; charset=UTF-8"><style>body { line-height: 1.5; }blockquote { margin-top: 0px; margin-bottom: 0px; margin-left: 0.5em; }body { font-size: 10.5pt; font-family: 'Microsoft YaHei UI'; color: rgb(0, 0, 0); line-height: 1.5; }</style></head><body>
<div><span></span><br></div><blockquote style="margin-Top: 0px; margin-Bottom: 0px; margin-Left: 0.5em"><div><div>Hi,adrian</div><div><br></div><div>I added a reply below your question.</div>
<div> </div>
<div>> -----Original Message-----</div>
<div>> From: openwrt-devel [mailto:openwrt-devel-bounces@lists.openwrt.org]</div>
<div>> On Behalf Of Luochongjun</div>
<div>> Sent: Donnerstag, 7. Mai 2020 13:47</div>
<div>> To: openwrt-devel@lists.openwrt.org</div>
<div>> Cc: Luochongjun <luochongjun@gl-inet.com></div>
<div>> Subject: [OpenWrt-Devel] [PATCH] ath79: add support for gl-e750</div>
<div>> </div>
<div>> The gl-e750 is a portable travel router that gives you safe access to the</div>
<div>> internet while traveling.</div>
<div>> </div>
<div>> Specifications:</div>
<div>> - SoC: Qualcomm Atheros AR9531 (650MHz)</div>
<div>> - RAM: 128 MB DDR2</div>
<div>> - Flash: 16 MB SPI NOR (W25Q128FVSG) + 128 MB SPI NAND</div>
<div>> (GD5F1GQ4UFYIG)</div>
<div>> - Ethernet: 10/100: 1xLAN</div>
<div>> - Wireless: QCA9531 2.4GHz (bgn) + QCA9887 5GHz (ac)</div>
<div>> - USB: 1x USB 2.0 port</div>
<div>> - Switch: 1x switch</div>
<div>> - Button: 1x reset button</div>
<div>> - OLED Screen: 128*64 px</div>
<div> </div>
<div>No LEDs?</div><div>--->Yes, No LEDs</div>
<div> </div>
<div>Some other comments below.</div>
<div> </div>
<div>> </div>
<div>> Flash instruction:</div>
<div>> Support for sysupgrade directive upgrades, as well as luci upgrades.</div>
<div>> </div>
<div>> OLED screen control:</div>
<div>> OLED controller is connected to QCA9531 through serial port, and can send</div>
<div>> instructions to OLED controller directly through serial port.</div>
<div>> Refer to the links below for a list of supported instructions:</div>
<div>> https://github.com/gl-inet/GL-E750-MCU-instruction</div>
<div>> </div>
<div>> Signed-off-by: Luochongjun <luochongjun@gl-inet.com></div>
<div>> ---</div>
<div>> target/linux/ath79/dts/qca9531_glinet_gl-e750.dts | 141</div>
<div>> +++++++++++++++++++++</div>
<div>> .../generic/base-files/etc/board.d/02_network | 1 +</div>
<div>> target/linux/ath79/image/nand.mk | 15 +++</div>
<div>> 3 files changed, 157 insertions(+)</div>
<div>> create mode 100644 target/linux/ath79/dts/qca9531_glinet_gl-e750.dts</div>
<div>> </div>
<div>> diff --git a/target/linux/ath79/dts/qca9531_glinet_gl-e750.dts</div>
<div>> b/target/linux/ath79/dts/qca9531_glinet_gl-e750.dts</div>
<div>> new file mode 100644</div>
<div>> index 0000000..645c69a</div>
<div>> --- /dev/null</div>
<div>> +++ b/target/linux/ath79/dts/qca9531_glinet_gl-e750.dts</div>
<div>> @@ -0,0 +1,141 @@</div>
<div>> +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/;</div>
<div>> +</div>
<div>> +#include <dt-bindings/gpio/gpio.h></div>
<div>> +#include <dt-bindings/input/input.h></div>
<div>> +</div>
<div>> +#include "qca953x.dtsi"</div>
<div>> +</div>
<div>> +/ {</div>
<div>> + compatible = "glinet,gl-e750", "qca,qca9531";</div>
<div>> + model = "GL.iNet GL-E750";</div>
<div>> +</div>
<div>> + keys {</div>
<div>> + compatible = "gpio-keys";</div>
<div>> +</div>
<div>> + pinctrl-names = "default";</div>
<div>> + pinctrl-0 = <&jtag_disable_pins>;</div>
<div>> +</div>
<div>> + reset {</div>
<div>> + label = "reset";</div>
<div>> + linux,code = <KEY_RESTART>;</div>
<div>> + gpios = <&gpio 3 GPIO_ACTIVE_LOW>;</div>
<div>> + };</div>
<div>> +</div>
<div>> + switch {</div>
<div>> + label = "switch";</div>
<div>> + linux,code = <BTN_0>;</div>
<div>> + gpios = <&gpio 1 GPIO_ACTIVE_LOW>;</div>
<div>> + };</div>
<div>> + };</div>
<div>> +</div>
<div>> + gpio-export {</div>
<div>> + compatible = "gpio-export";</div>
<div>> + #size-cells = <0>;</div>
<div>> +</div>
<div>> + gpio_lte_power {</div>
<div>> + gpio-export,name = "lte";</div>
<div> </div>
<div>I'd consider lte-power or lte_power as name here.</div><div>--->I agree. It's easier to understand</div>
<div> </div>
<div>> + gpio-export,output = <1>;</div>
<div>> + gpios = <&gpio 0 GPIO_ACTIVE_HIGH>;</div>
<div>> + };</div>
<div>> + };</div>
<div>> +</div>
<div>> +};</div>
<div>> +</div>
<div>> +&pcie0 {</div>
<div>> + status = "okay";</div>
<div>> +};</div>
<div>> +</div>
<div>> +&uart {</div>
<div>> + status = "okay";</div>
<div>> +};</div>
<div>> +</div>
<div>> +&usb0 {</div>
<div>> + #address-cells = <1>;</div>
<div>> + #size-cells = <0>;</div>
<div>> + status = "okay";</div>
<div>> +</div>
<div>> + hub_port: port@1 {</div>
<div>> + reg = <1>;</div>
<div>> + #trigger-source-cells = <0>;</div>
<div>> + };</div>
<div>> +};</div>
<div>> +</div>
<div>> +&usb_phy {</div>
<div>> + status = "okay";</div>
<div>> +};</div>
<div>> +</div>
<div>> +&spi {</div>
<div>> + status = "okay";</div>
<div>> + num-cs = <2>;</div>
<div>> +</div>
<div>> + flash@0 {</div>
<div>> + compatible = "jedec,spi-nor";</div>
<div>> + reg = <0>;</div>
<div>> + spi-max-frequency = <25000000>;</div>
<div>> +</div>
<div>> + partitions {</div>
<div>> + compatible = "fixed-partitions";</div>
<div>> + #address-cells = <1>;</div>
<div>> + #size-cells = <1>;</div>
<div>> +</div>
<div>> + partition@0 {</div>
<div>> + label = "u-boot";</div>
<div>> + reg = <0x0 0x40000>;</div>
<div>> + read-only;</div>
<div>> + };</div>
<div>> +</div>
<div>> + partition@40000 {</div>
<div>> + label = "u-boot-env";</div>
<div>> + reg = <0x40000 0x10000>;</div>
<div>> + };</div>
<div>> +</div>
<div>> + art: partition@50000 {</div>
<div>> + label = "art";</div>
<div>> + reg = <0x50000 0x10000>;</div>
<div>> + read-only;</div>
<div>> + };</div>
<div>> +</div>
<div>> + partition@60000 {</div>
<div>> + label = "kernel";</div>
<div>> + reg = <0x60000 0x400000>;</div>
<div>> + };</div>
<div>> +</div>
<div>> + partition@460000 {</div>
<div>> + label = "reserved";</div>
<div>> + reg = <0x460000 0xba0000>;</div>
<div>> + };</div>
<div>> +</div>
<div>> + };</div>
<div>> + };</div>
<div>> +</div>
<div>> + flash@1 {</div>
<div>> + compatible = "spi-nand";</div>
<div>> + reg = <1>;</div>
<div>> + spi-max-frequency = <25000000>;</div>
<div>> +</div>
<div>> + partitions {</div>
<div>> + compatible = "fixed-partitions";</div>
<div>> + #address-cells = <1>;</div>
<div>> + #size-cells = <1>;</div>
<div>> +</div>
<div>> + partition@0 {</div>
<div>> + label = "ubi";</div>
<div>> + reg = <0x0 0x8000000>;</div>
<div>> + };</div>
<div>> + };</div>
<div>> + };</div>
<div>> +};</div>
<div>> +</div>
<div>> +ð0 {</div>
<div>> + status = "okay";</div>
<div>> +</div>
<div>> + mtd-mac-address = <&art 0x0>;</div>
<div>> + phy-handle = <&swphy4>;</div>
<div>> +};</div>
<div>> +</div>
<div>> +&wmac {</div>
<div>> + status = "okay";</div>
<div>> + mtd-cal-data = <&art 0x1000>;</div>
<div>> + mtd-mac-address = <&art 0x1002>;</div>
<div> </div>
<div>mtd-mac-address can be dropped here, as it will be read from this offset by mtd-cal-data automatically.</div><div>---> Will the offset of 0x2 be automatically added?</div>
<div> </div>
<div>> +};</div>
<div>> diff --git a/target/linux/ath79/generic/base-files/etc/board.d/02_network</div>
<div>> b/target/linux/ath79/generic/base-files/etc/board.d/02_network</div>
<div>> index d7f7eed..a50dfec 100755</div>
<div>> --- a/target/linux/ath79/generic/base-files/etc/board.d/02_network</div>
<div>> +++ b/target/linux/ath79/generic/base-files/etc/board.d/02_network</div>
<div>> @@ -23,6 +23,7 @@ ath79_setup_interfaces()</div>
<div>> dlink,dir-505|\</div>
<div>> engenius,ecb1750|\</div>
<div>> glinet,gl-ar300m-lite|\</div>
<div>> + glinet,gl-e750|\</div>
<div>> netgear,ex6400|\</div>
<div>> netgear,ex7300|\</div>
<div>> ocedo,koala|\</div>
<div>> diff --git a/target/linux/ath79/image/nand.mk</div>
<div>> b/target/linux/ath79/image/nand.mk</div>
<div>> index 3ccd199..e6743e4 100644</div>
<div>> --- a/target/linux/ath79/image/nand.mk</div>
<div>> +++ b/target/linux/ath79/image/nand.mk</div>
<div>> @@ -130,6 +130,21 @@ define Device/glinet_gl-ar750s-nor endef</div>
<div>> TARGET_DEVICES += glinet_gl-ar750s-nor</div>
<div>> </div>
<div>> +define Device/glinet_gl-e750</div>
<div>> + SOC := qca9531</div>
<div>> + DEVICE_VENDOR := GL.iNet</div>
<div>> + DEVICE_MODEL := GL-E750</div>
<div>> + DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca9887-ct kmod-</div>
<div>> usb2 \</div>
<div>> + kmod-usb-storage block-mount</div>
<div>> + KERNEL_SIZE := 4096k</div>
<div>> + IMAGE_SIZE := 131072k</div>
<div>> + PAGESIZE := 2048</div>
<div>> + VID_HDR_OFFSET := 2048</div>
<div>> + BLOCKSIZE := 128k</div>
<div>> + IMAGES += factory.img</div>
<div> </div>
<div>Typically, GL.inet devices can be installed with sysupgrade, so a factory image is not necessary? (And it's not set up anyway)</div>
<div>I think this can be dropped.</div><div>--->Many GL users like to use uboot to upgrade their firmware, so I think it is necessary to generate a factory image.</div>
<div> </div>
<div>If you send a newer patch, please make sure to add a v2 ...</div><div>--->Thank you. I will submit it as required</div>
<div> </div>
<div>Best</div>
<div> </div>
<div>Adrian</div>
<div> </div>
<div>> +endef</div>
<div>> +TARGET_DEVICES += glinet_gl-e750</div>
<div>> +</div>
<div>> # fake rootfs is mandatory, pad-offset 129 equals (2 * uimage_header +</div>
<div>> 0xff) define Device/netgear_ath79_nand</div>
<div>> DEVICE_VENDOR := NETGEAR</div>
<div>> --</div>
<div>> 2.7.4</div>
<div>> </div>
<div>> </div>
<div>> </div>
<div>> </div>
<div>> _______________________________________________</div>
<div>> openwrt-devel mailing list</div>
<div>> openwrt-devel@lists.openwrt.org</div>
<div><span microsoft="" yahei="" ui';="" font-size:="" 14px;="" color:="" rgb(0,="" 0,="" 0);="" background-color:="" rgba(0,="" font-weight:="" normal;="" font-style:="" normal;text-decoration:="" none;'="" style="font-size: 10.5pt; line-height: 1.5; background-color: transparent;">></span><span style="font-size: 10.5pt; line-height: 1.5; background-color: transparent;"> </span><a href="https://lists.openwrt.org/mailman/listinfo/openwrt-devel" microsoft="" yahei="" ui';="" font-size:="" 14px;="" font-weight:="" normal;="" font-style:="" normal;'="" style="font-size: 10.5pt; line-height: 1.5; background-color: transparent;">https://lists.openwrt.org/mailman/listinfo/openwrt-devel</a><span microsoft="" yahei="" ui';="" font-size:="" 14px;="" color:="" rgb(0,="" 0,="" 0);="" background-color:="" rgba(0,="" font-weight:="" normal;="" font-style:="" normal;text-decoration:="" none;'="" style="font-size: 10.5pt; line-height: 1.5; background-color: transparent;"> </span></div><div><span microsoft="" yahei="" ui';="" font-size:="" 14px;="" color:="" rgb(0,="" 0,="" 0);="" background-color:="" rgba(0,="" font-weight:="" normal;="" font-style:="" normal;text-decoration:="" none;'="" style="font-size: 10.5pt; line-height: 1.5; background-color: transparent;"><br></span></div><div><span microsoft="" yahei="" ui';="" font-size:="" 14px;="" color:="" rgb(0,="" 0,="" 0);="" background-color:="" rgba(0,="" font-weight:="" normal;="" font-style:="" normal;text-decoration:="" none;'="" style="font-size: 10.5pt; line-height: 1.5; background-color: transparent;">Best regards,</span></div><div><span microsoft="" yahei="" ui';="" font-size:="" 14px;="" color:="" rgb(0,="" 0,="" 0);="" background-color:="" rgba(0,="" font-weight:="" normal;="" font-style:="" normal;text-decoration:="" none;'="" style="font-size: 10.5pt; line-height: 1.5; background-color: transparent;">Luochongjn</span></div>
</div></blockquote>
</body></html>