From patchwork Sat Apr 23 15:49:34 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan-Niklas Burfeind X-Patchwork-Id: 1621420 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=sZIUz0cy; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=aiyionpri.me header.i=@aiyionpri.me header.a=rsa-sha256 header.s=strato-dkim-0002 header.b=nyUL5Ra2; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.openwrt.org (client-ip=2607:7c80:54:e::133; helo=bombadil.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=) Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4KlwpZ4H6Tz9s75 for ; Sun, 24 Apr 2022 01:55:18 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=VnfWrOt1OFLzQRiVSGOpMflQXn9nbX6EfRdFgnFDO38=; b=sZIUz0cyzd/5Y3 dmI9OGCsfinIdIGxOzXFxlr09mPMaYK9nJLF0zI7XBBIAR7azhpvnrfikEqqxKK9RPGetv7l/7kZS rM7RRv6Oxd5NVHP0S7RvkFOZFqbXHbId9OoC19opy41RjLfnKRe5cLk8wvpkST+uCIVMy8MduhJYT q+KiDFvsKlX2YumZXeEeUObQG+fmNd111cx6b9i5bOJ/9vk0ZQmv1z/n7JOzSuYAPKh6w0Gn2tGcl BCWY0wRCutLr/9cRaHaMwZ0iEKcBxQ8OhjgDqlqpMdrg/NiL+vBW4T7moHjNQLbh8iyahJmqCXl9h Emvcs2RyIap/smIA+6xA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1niI1V-004abk-4J; Sat, 23 Apr 2022 15:50:13 +0000 Received: from mo4-p00-ob.smtp.rzone.de ([85.215.255.25]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1niI1N-004aak-Gp for openwrt-devel@lists.openwrt.org; Sat, 23 Apr 2022 15:50:07 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1650728989; s=strato-dkim-0002; d=aiyionpri.me; h=Message-Id:Date:Subject:Cc:To:From:Cc:Date:From:Subject:Sender; bh=bmy38hjs5RDYosyGYHdc9ktXmWJpXS+l/BsWvQROmxM=; b=nyUL5Ra2wzbRT2Mq/qQ64Jq4wNiiBP2GM+4IKIjhoEmSFEBDrzNSJ2Myqx0Sl9dWqU MfKxM0f7tY7+jbYBlASq6d1vLA90/SMaV5GQ1tHl1VmLnjSWzwq7iUck7BECc+77P/EM 3wHRDjqVGa0sp5H+2L8Z+MhyAVqcaEU4u7pIVPXDfuv+8NLveBdJwCNoVRULVJn6ovk7 o00FO3PzVcn/zgVpTZdTFzQGUKEh65LzSn2sJb5GmIlUVMaXYwvKnYYe7h1OVHHrhDid m3HyoxPb1BEyK5KMZP9M9e+kpcHGWMKRAFAKhC5F8ZLOhTQZIx4GpsnccQxVNaCSIE2T 5B5A== Authentication-Results: strato.com; dkim=none X-RZG-AUTH: ":IWkkdEmxcvCtRDtHUQOu48a0Nfy9hOkboq9r6d0vrgVDHZTjCI2AM0yZX6WZJhCkH8hFv8I8nf0mXmmcIm6y6Bx2bWVPv2xVnDLq8Q==" X-RZG-CLASS-ID: mo00 Received: from chromia.fritz.box by smtp.strato.de (RZmta 47.42.2 AUTH) with ESMTPSA id Vc7959y3NFnmSQ8 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits)) (Client did not present a certificate); Sat, 23 Apr 2022 17:49:48 +0200 (CEST) From: Jan-Niklas Burfeind To: openwrt-devel@lists.openwrt.org Cc: Matthias Schiffer , David Bauer , Jan-Niklas Burfeind Subject: [PATCH v3] ath79: add support for Ubiquiti NanoBeam M5 Date: Sat, 23 Apr 2022 17:49:34 +0200 Message-Id: <20220423154934.11188-1-git@aiyionpri.me> X-Mailer: git-send-email 2.36.0 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220423_085005_946342_022EB692 X-CRM114-Status: GOOD ( 12.59 ) X-Spam-Score: -0.2 (/) X-Spam-Report: Spam detection software, running on the system "bombadil.infradead.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Ubiquiti NanoBeam M5 devices are CPE equipment for customer locations with one Ethernet port and a 5 GHz 300Mbps wireless interface. Specificatons: - Atheros AR9342 - 535 MHz CPU - 64 MB RAM - 8 MB Flash - 1x 10/100 Mbps Ethernet with passive PoE input (24 V) - 6 LEDs of which four are rssi - 1 reset button - UART (4-pin) header on PCB Content analysis details: (-0.2 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [85.215.255.25 listed in list.dnswl.org] 0.0 SPF_NONE SPF: sender does not publish an SPF Record -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "openwrt-devel" Errors-To: openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org Ubiquiti NanoBeam M5 devices are CPE equipment for customer locations with one Ethernet port and a 5 GHz 300Mbps wireless interface. Specificatons: - Atheros AR9342 - 535 MHz CPU - 64 MB RAM - 8 MB Flash - 1x 10/100 Mbps Ethernet with passive PoE input (24 V) - 6 LEDs of which four are rssi - 1 reset button - UART (4-pin) header on PCB Notes: The device was supported by OpenWrt in ar71xx. Flash instructions (web/ssh/tftp): Loading the image via ssh vias a stock firmware prior "AirOS 5.6". Downgrading stock is possible. * Flashing is possible via AirOS software update page: The "factory" ROM image is recognized as non-native and then installed correctly. AirOS warns to better be familiar with the recovery procedure. * Flashing can be done via ssh, which is becoming difficult due to legacy keyexchange methods. This is an exempary ssh-config: KexAlgorithms +diffie-hellman-group1-sha1 HostKeyAlgorithms ssh-rsa PubkeyAcceptedKeyTypes ssh-rsa User ubnt The password is ubnt. Connecting via IPv6 link local worked best for me. 1. scp the factory image to /tmp 2. fwupdate.real -m /tmp/firmware_image_file.bin -d * Alternatively tftp is possible: 1. Configure PC with static IP 192.168.1.2/24. 2. Enter the rescue mode. Power off the device, push the reset button on the device (or the PoE) and keep it pressed. Power on the device, while still pushing the reset button. 3. When all the leds blink at the same time, release the reset button. 4. Upload the firmware image file via TFTP: tftp 192.168.1.20 tftp> bin tftp> trace Packet tracing on. tftp> put firmware_image.bin Signed-off-by: Jan-Niklas Burfeind --- Sorry for messing up the versioning earlier, this is v3 not v2. .../ath79/dts/ar9342_ubnt_nanobeam-m5.dts | 26 +++++++++++++++++++ target/linux/ath79/image/generic-ubnt.mk | 8 ++++++ 2 files changed, 34 insertions(+) create mode 100644 target/linux/ath79/dts/ar9342_ubnt_nanobeam-m5.dts diff --git a/target/linux/ath79/dts/ar9342_ubnt_nanobeam-m5.dts b/target/linux/ath79/dts/ar9342_ubnt_nanobeam-m5.dts new file mode 100644 index 0000000000..86a5e3a751 --- /dev/null +++ b/target/linux/ath79/dts/ar9342_ubnt_nanobeam-m5.dts @@ -0,0 +1,26 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT + +#include "ar9342_ubnt_xw.dtsi" + +/ { + compatible = "ubnt,nanobeam-m5-xw", "ubnt,xw", "qca,ar9342"; + model = "Ubiquiti NanoBeam M5 (XW)"; +}; + +&mdio0 { + status = "okay"; + + phy-mask = <0x1>; + + phy1: ethernet-phy@1 { + reg = <1>; + phy-mode = "mii"; + reset-gpios = <&gpio 0 GPIO_ACTIVE_LOW>; + }; +}; + +ð0 { + status = "okay"; + + phy-handle = <&phy1>; +}; diff --git a/target/linux/ath79/image/generic-ubnt.mk b/target/linux/ath79/image/generic-ubnt.mk index 0b613df62b..9de83d42c2 100644 --- a/target/linux/ath79/image/generic-ubnt.mk +++ b/target/linux/ath79/image/generic-ubnt.mk @@ -255,6 +255,14 @@ define Device/ubnt_nanobeam-ac-xc endef TARGET_DEVICES += ubnt_nanobeam-ac-xc +define Device/ubnt_nanobeam-m5 + $(Device/ubnt-xw) + DEVICE_MODEL := NanoBeam M5 + DEVICE_PACKAGES += rssileds + SUPPORTED_DEVICES += loco-m-xw +endef +TARGET_DEVICES += ubnt_nanobeam-m5 + define Device/ubnt_nanobridge-m $(Device/ubnt-xm) SOC := ar7241