[OpenWrt-Devel] [PATCH 2/2] ramips: mt7530: more detailed output for unexpected etag_ctrl
Signed-off-by: Yousong Zhou --- .../ramips/files-4.14/drivers/net/ethernet/mediatek/mt7530.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/target/linux/ramips/files-4.14/drivers/net/ethernet/mediatek/mt7530.c b/target/linux/ramips/files-4.14/drivers/net/ethernet/mediatek/mt7530.c index 8ffd614d9f..d1e56a76e9 100644 --- a/target/linux/ramips/files-4.14/drivers/net/ethernet/mediatek/mt7530.c +++ b/target/linux/ramips/files-4.14/drivers/net/ethernet/mediatek/mt7530.c @@ -435,7 +435,8 @@ mt7530_get_vlan_ports(struct switch_dev *dev, struct switch_val *val) if (etag == ETAG_CTRL_TAG) p->flags |= BIT(SWITCH_PORT_FLAG_TAGGED); else if (etag != ETAG_CTRL_UNTAG) - printk("vlan egress tag control neither untag nor tag.\n"); + printk("vlan %d port %d egress tag control neither untag nor tag: %d.\n", + val->port_vlan, i, etag); } return 0; ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH 1/2] ramips: mt7530: remove redundant global attrs for port mirroring
Global attributes enable_mirror_tx/enable_mirror_rx depend on runtime value of another global attribute mirror_source_port which just resides in the memory The same functionality can be achieved by directly setting port attribute of the same names. E.g. the following two groups of commands achieve the same thing swconfig dev switch0 set mirror_source_port 3 swconfig dev switch0 set enable_mirror_tx 1 swconfig dev switch0 set mirror_source_port 4 swconfig dev switch0 set enable_mirror_tx 1 swconfig dev switch0 port 3 set enable_mirror_tx 1 swconfig dev switch0 port 4 set enable_mirror_tx 1 Signed-off-by: Yousong Zhou --- .../drivers/net/ethernet/mediatek/mt7530.c| 88 --- 1 file changed, 88 deletions(-) diff --git a/target/linux/ramips/files-4.14/drivers/net/ethernet/mediatek/mt7530.c b/target/linux/ramips/files-4.14/drivers/net/ethernet/mediatek/mt7530.c index 9acea3bc84..8ffd614d9f 100644 --- a/target/linux/ramips/files-4.14/drivers/net/ethernet/mediatek/mt7530.c +++ b/target/linux/ramips/files-4.14/drivers/net/ethernet/mediatek/mt7530.c @@ -208,7 +208,6 @@ struct mt7530_priv { struct mii_bus *bus; struct switch_dev swdev; - u8 mirror_src_port; u8 mirror_dest_port; boolglobal_vlan_enable; struct mt7530_vlan_entryvlan_entries[MT7530_NUM_VLANS]; @@ -519,50 +518,6 @@ mt7530_get_vid(struct switch_dev *dev, const struct switch_attr *attr, return 0; } -static int -mt7530_get_mirror_rx_enable(struct switch_dev *dev, const struct switch_attr *attr, - struct switch_val *val) -{ - struct mt7530_priv *priv = container_of(dev, struct mt7530_priv, swdev); - - val->value.i = priv->port_entries[priv->mirror_src_port].mirror_rx; - - return 0; -} - -static int -mt7530_set_mirror_rx_enable(struct switch_dev *dev, const struct switch_attr *attr, - struct switch_val *val) -{ - struct mt7530_priv *priv = container_of(dev, struct mt7530_priv, swdev); - - priv->port_entries[priv->mirror_src_port].mirror_rx = val->value.i; - - return 0; -} - -static int -mt7530_get_mirror_tx_enable(struct switch_dev *dev, const struct switch_attr *attr, - struct switch_val *val) -{ - struct mt7530_priv *priv = container_of(dev, struct mt7530_priv, swdev); - - val->value.i = priv->port_entries[priv->mirror_src_port].mirror_tx; - - return 0; -} - -static int -mt7530_set_mirror_tx_enable(struct switch_dev *dev, const struct switch_attr *attr, - struct switch_val *val) -{ - struct mt7530_priv *priv = container_of(dev, struct mt7530_priv, swdev); - - priv->port_entries[priv->mirror_src_port].mirror_tx = val->value.i; - - return 0; -} - static int mt7530_get_mirror_monitor_port(struct switch_dev *dev, const struct switch_attr *attr, struct switch_val *val) @@ -585,28 +540,6 @@ mt7530_set_mirror_monitor_port(struct switch_dev *dev, const struct switch_attr return 0; } -static int -mt7530_get_mirror_source_port(struct switch_dev *dev, const struct switch_attr *attr, - struct switch_val *val) -{ - struct mt7530_priv *priv = container_of(dev, struct mt7530_priv, swdev); - - val->value.i = priv->mirror_src_port; - - return 0; -} - -static int -mt7530_set_mirror_source_port(struct switch_dev *dev, const struct switch_attr *attr, - struct switch_val *val) -{ - struct mt7530_priv *priv = container_of(dev, struct mt7530_priv, swdev); - - priv->mirror_src_port = val->value.i; - - return 0; -} - static int mt7530_get_port_mirror_rx(struct switch_dev *dev, const struct switch_attr *attr, struct switch_val *val) @@ -1002,20 +935,6 @@ static const struct switch_attr mt7530_global[] = { .description = "Get MIB counters for switch", .get = mt7530_sw_get_mib, .set = NULL, - }, { - .type = SWITCH_TYPE_INT, - .name = "enable_mirror_rx", - .description = "Enable mirroring of RX packets", - .set = mt7530_set_mirror_rx_enable, - .get = mt7530_get_mirror_rx_enable, - .max = 1 - }, { - .type = SWITCH_TYPE_INT, - .name = "enable_mirror_tx", - .description = "Enable mirroring of TX packets", - .set = mt7530_set_mirror_tx_enable, - .get = mt7530_get_mirror_tx_enable, - .max = 1 }, { .type = SWITCH_TYPE_INT, .name = "mirror_monitor_port", @@ -1023,13 +942,6 @@ static const struct switch_attr mt7530_global[] = { .set = mt7530_set_mirror_monitor_port, .get = mt7530_get_mirror_monitor_port, .max =
[OpenWrt-Devel] [PATCH v2] build: refactor JSON info files to `profiles.json`
JSON info files contain machine readable information of built profiles and resulting images. These files where added via 881ed09ee6e2. They are useful for firmware wizards and script checking for reproducibility. Currently all JSON files are stored next to the built images, resulting in up to 168 individual files for the ath79/generic target. This PR refactors the JSON creation to store individual files in $(KDIR)/tmp and create an single overview file called `profiles.json` in the target dir. As before, this creation is enabled by default only if `BUILDBOT` is set. The previous implementation used the functions `json.dumps()` which seem to have caused broken files. Now the `pathlib` library is used to deal with files and the `json` library only reads/writes into variables. Tested via buildroot & ImageBuilder on ath79/generic. Signed-off-by: Paul Spooren --- v2: * One instead of three CONFIG options * Only created `profiles.json` without copying individual JSON files * Add merging functionality to ImageBuilder * Use underscores in Makefile function name * Fix wrong `rm -f` path (missing /tmp) * Use `pathlib` instead of `json.dump` * Use `os.getenv` from Python stdlib * Remove "generic" subtarget fallback as it is implement in image.mk Makefile| 6 config/Config-build.in | 10 --- include/image.mk| 6 ++-- scripts/json_add_image_info.py | 45 ++--- scripts/json_overview_image_info.py | 33 + target/imagebuilder/files/Makefile | 7 + 6 files changed, 77 insertions(+), 30 deletions(-) create mode 100755 scripts/json_overview_image_info.py diff --git a/Makefile b/Makefile index 181c33b180..b9f92babf6 100644 --- a/Makefile +++ b/Makefile @@ -96,6 +96,11 @@ buildversion: FORCE feedsversion: FORCE $(SCRIPT_DIR)/feeds list -fs > $(BIN_DIR)/feeds.buildinfo +json_overview_image_info: FORCE + INPUT_DIR=$(BUILD_DIR)/linux-$(BOARD)$(if $(SUBTARGET),_$(SUBTARGET))/tmp \ + TARGET_DIR=$(BIN_DIR) \ + $(SCRIPT_DIR)/json_overview_image_info.py + diffconfig: FORCE mkdir -p $(BIN_DIR) $(SCRIPT_DIR)/diffconfig.sh > $(BIN_DIR)/config.buildinfo @@ -108,6 +113,7 @@ prepare: .config $(tools/stamp-compile) $(toolchain/stamp-compile) world: prepare $(target/stamp-compile) $(package/stamp-compile) $(package/stamp-install) $(target/stamp-install) FORCE $(_SINGLE)$(SUBMAKE) -r package/index + $(if $(CONFIG_JSON_OVERVIEW_IMAGE_INFO),$(_SINGLE)$(SUBMAKE) -r json_overview_image_info) $(_SINGLE)$(SUBMAKE) -r checksum .PHONY: clean dirclean prereq prepare world package/symlinks package/symlinks-install package/symlinks-clean diff --git a/config/Config-build.in b/config/Config-build.in index 6a6fb2882c..57428399ab 100644 --- a/config/Config-build.in +++ b/config/Config-build.in @@ -7,12 +7,14 @@ menu "Global build settings" - config JSON_ADD_IMAGE_INFO - bool "Create JSON info files per build image" + config JSON_OVERVIEW_IMAGE_INFO + bool "Create JSON info file overview per target" default BUILDBOT + select JSON_CREATE_IMAGE_INFO help - The JSON info files contain information about the device and - build images, stored next to the firmware images. + Create a JSON info file called profiles.json in the target + directory containing machine readable list of built profiles + and resulting images. config ALL_NONSHARED bool "Select all target specific packages by default" diff --git a/include/image.mk b/include/image.mk index fd04d4020b..933d844e8e 100644 --- a/include/image.mk +++ b/include/image.mk @@ -568,9 +568,9 @@ define Device/Build/image $(BIN_DIR)/$(call IMAGE_NAME,$(1),$(2)): $(KDIR)/tmp/$(call IMAGE_NAME,$(1),$(2)) cp $$^ $$@ - $(if $(CONFIG_JSON_ADD_IMAGE_INFO), \ + $(if $(CONFIG_JSON_OVERVIEW_IMAGE_INFO), \ DEVICE_ID="$(DEVICE_NAME)" \ - BIN_DIR="$(BIN_DIR)" \ + BIN_DIR="$(KDIR)/tmp" \ IMAGE_NAME="$(IMAGE_NAME)" \ IMAGE_TYPE=$(word 1,$(subst ., ,$(2))) \ IMAGE_PREFIX="$(IMAGE_PREFIX)" \ @@ -612,7 +612,7 @@ define Device/Build/artifact endef define Device/Build - $(shell rm -f $(BIN_DIR)/$(IMG_PREFIX)-$(1).json) + $(shell rm -f $(KDIR)/tmp/$(IMG_PREFIX)-$(1).json) $(if $(CONFIG_TARGET_ROOTFS_INITRAMFS),$(call Device/Build/initramfs,$(1))) $(call Device/Build/kernel,$(1)) diff --git a/scripts/json_add_image_info.py b/scripts/json_add_image_info.py index 44b4031f85..c7f28a2183 100755 --- a/scripts/json_add_image_info.py +++ b/scripts/json_add_image_info.py @@ -1,18 +1,15 @@ #!/usr/bin/env python3 import json -import os +from os import getenv import hashlib +from
Re: [OpenWrt-Devel] Kernel 5.4 testing: module regressions (exfat, IPv6 NAT)
> I tested the kernel 5.4 support with ipq806x/R7800 and noticed that at least > two kernel packages get broken with 5.4: > > * exfat-nofuse: exFAT is included in Linux 5.4 as a driver in the staging > section. The header definitions in exfat-nofuse conflict with the ones > already in Linux 5.4 be default. The new kernel module should probably be > packaged in OpenWrt with a depndency to 5.4 (and exfat-nofuse disabled in > 5.4+ as they define the same kmod-fs-exfat) > > https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/drivers/staging/exfat?h=linux-5.4.y > > > * IPv6 NAT breaks compilation: fails if ip6tables-mod-nat and kmod-ipt-nat6 > are included in the build. Likely netfilter requires some modifications. > > Collected errors: > * check_data_file_clashes: Package kmod-ipt-nat6 wants to install file > /Openwrt/r7800/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/root-ipq806x/lib/modules/5.4.22/xt_MASQUERADE.ko > But that file is already provided by package * kmod-ipt-nat > * opkg_install_cmd: Cannot install package kmod-ipt-nat6. > * check_data_file_clashes: Package kmod-ipt-nat6 wants to install file > /Openwrt/r7800/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/root-ipq806x/lib/modules/5.4.22/xt_MASQUERADE.ko > But that file is already provided by package * kmod-ipt-nat > * opkg_install_cmd: Cannot install package ip6tables-mod-nat. > > > ___ > openwrt-devel mailing list > openwrt-devel@lists.openwrt.org > https://lists.openwrt.org/mailman/listinfo/openwrt-devel Also from long ago I have this error that has never been fixed config:4110:warning: symbol value 'm' invalid for NF_NAT_REDIRECT ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [RFC PATCH] kernel: backport and package drivetemp hwmon from v5.5
This patch backports the hwmon drivetemp sensor module from vanilla linux 5.5 to be available on OpenWrt's 5.4 kernel. Extract from The upstream commit by Guenter Roeck : hwmon: Driver for disk and solid state drives with temperature sensors "Reading the temperature of ATA drives has been supported for years by userspace tools such as smarttools or hddtemp. The downside of such tools is that they need to run with super-user privilege, that the temperatures are not reported by standard tools such as 'sensors' or 'libsensors', and that drive temperatures are not available for use in the kernel's thermal subsystem. This driver solves this problem by adding support for reading the temperature of ATA drives from the kernel using the hwmon API and by adding a temperature zone for each drive. With this driver, the hard disk temperature can be read [...] using sysfs: $ grep . /sys/class/hwmon/hwmon9/{name,temp1_input} /sys/class/hwmon/hwmon9/name:drivetemp /sys/class/hwmon/hwmon9/temp1_input:23000 If the drive supports SCT transport and reports temperature limits, those are reported as well. drivetemp-scsi-0-0 Adapter: SCSI adapter temp1:+27.0C (low = +0.0C, high = +60.0C) (crit low = -41.0C, crit = +85.0C) (lowest = +23.0C, highest = +34.0C) The driver attempts to use SCT Command Transport to read the drive temperature. If the SCT Command Transport feature set is not available, or if it does not report the drive temperature, drive temperatures may be readable through SMART attributes. Since SMART attributes are not well defined, this method is only used as fallback mechanism." Signed-off-by: Christian Lamparter --- My motivation for packaging this module comes from making the WNDR4700 to behave as close to what the Netgear's firmware does. The fan should kick in when the drive gets hot and for this to work, the cooling zones need to have a proper sensor that has the temperature of the HDD to properly control the cooling device. --- package/kernel/linux/modules/hwmon.mk | 15 + ...sfs-attributes-for-VPD-pages-0h-and-.patch | 122 +++ ...-disk-and-solid-state-drives-with-te.patch | 737 ++ 3 files changed, 874 insertions(+) create mode 100644 target/linux/generic/backport-5.4/800-v5.5-scsi-core-Add-sysfs-attributes-for-VPD-pages-0h-and-.patch create mode 100644 target/linux/generic/backport-5.4/801-v5.5-hwmon-Driver-for-disk-and-solid-state-drives-with-te.patch diff --git a/package/kernel/linux/modules/hwmon.mk b/package/kernel/linux/modules/hwmon.mk index c0a477856e..ed0ee44241 100644 --- a/package/kernel/linux/modules/hwmon.mk +++ b/package/kernel/linux/modules/hwmon.mk @@ -77,6 +77,21 @@ endef $(eval $(call KernelPackage,hwmon-adt7475)) +define KernelPackage/hwmon-drivetemp + TITLE:=Hard disk drives with temperature sensor + KCONFIG:=CONFIG_SENSORS_DRIVETEMP + FILES:=$(LINUX_DIR)/drivers/hwmon/drivetemp.ko + AUTOLOAD:=$(call AutoLoad,60,drivetemp) + $(call AddDepends/hwmon,+kmod-ata-core +kmod-scsi-core) +endef + +define KernelPackage/hwmon-drivetemp/description + Kernel module for Hard disk drives with temperature sensor +endef + +$(eval $(call KernelPackage,hwmon-drivetemp)) + + define KernelPackage/hwmon-gpiofan TITLE:=Generic GPIO FAN support KCONFIG:=CONFIG_SENSORS_GPIO_FAN diff --git a/target/linux/generic/backport-5.4/800-v5.5-scsi-core-Add-sysfs-attributes-for-VPD-pages-0h-and-.patch b/target/linux/generic/backport-5.4/800-v5.5-scsi-core-Add-sysfs-attributes-for-VPD-pages-0h-and-.patch new file mode 100644 index 00..dc89b279e5 --- /dev/null +++ b/target/linux/generic/backport-5.4/800-v5.5-scsi-core-Add-sysfs-attributes-for-VPD-pages-0h-and-.patch @@ -0,0 +1,122 @@ +From d188b0675b21d5a6ca27b3e741381813983f4719 Mon Sep 17 00:00:00 2001 +From: Ryan Attard +Date: Thu, 26 Sep 2019 11:22:17 -0500 +Subject: [PATCH] scsi: core: Add sysfs attributes for VPD pages 0h and 89h + +Add sysfs attributes for the ATA information page and Supported VPD Pages +page. + +Link: https://lore.kernel.org/r/20190926162216.56591-1-ryanatt...@ryanattard.info +Signed-off-by: Ryan Attard +Reviewed-by: Bart Van Assche +Signed-off-by: Martin K. Petersen +--- + drivers/scsi/scsi.c| 4 + drivers/scsi/scsi_sysfs.c | 19 +++ + include/scsi/scsi_device.h | 2 ++ + 3 files changed, 25 insertions(+) + +--- a/drivers/scsi/scsi.c b/drivers/scsi/scsi.c +@@ -465,10 +465,14 @@ void scsi_attach_vpd(struct scsi_device + return; + + for (i = 4; i < vpd_buf->len; i++) { ++ if (vpd_buf->data[i] == 0x0) ++ scsi_update_vpd_page(sdev, 0x0, >vpd_pg0); + if (vpd_buf->data[i] == 0x80) + scsi_update_vpd_page(sdev, 0x80, >vpd_pg80); + if (vpd_buf->data[i] == 0x83) + scsi_update_vpd_page(sdev, 0x83, >vpd_pg83); ++ if (vpd_buf->data[i] == 0x89) ++
[OpenWrt-Devel] Kernel 5.4 testing: module regressions (exfat, IPv6 NAT)
I tested the kernel 5.4 support with ipq806x/R7800 and noticed that at least two kernel packages get broken with 5.4: * exfat-nofuse: exFAT is included in Linux 5.4 as a driver in the staging section. The header definitions in exfat-nofuse conflict with the ones already in Linux 5.4 be default. The new kernel module should probably be packaged in OpenWrt with a depndency to 5.4 (and exfat-nofuse disabled in 5.4+ as they define the same kmod-fs-exfat) https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/drivers/staging/exfat?h=linux-5.4.y * IPv6 NAT breaks compilation: fails if ip6tables-mod-nat and kmod-ipt-nat6 are included in the build. Likely netfilter requires some modifications. Collected errors: * check_data_file_clashes: Package kmod-ipt-nat6 wants to install file /Openwrt/r7800/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/root-ipq806x/lib/modules/5.4.22/xt_MASQUERADE.ko But that file is already provided by package * kmod-ipt-nat * opkg_install_cmd: Cannot install package kmod-ipt-nat6. * check_data_file_clashes: Package kmod-ipt-nat6 wants to install file /Openwrt/r7800/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/root-ipq806x/lib/modules/5.4.22/xt_MASQUERADE.ko But that file is already provided by package * kmod-ipt-nat * opkg_install_cmd: Cannot install package ip6tables-mod-nat. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] ImageBuilder: satisfy_dependencies_for [...] iw
Paul Spooren wrote at Sat Feb 29 03:55:54 PST 2020 > > for the last few days I get the following error for multiple targets, > would it be possible to rerun the snapshot servers to rebuild the > package `iw`? > > $ make manifest PROFILE="devolo_dvl1750e" > > [...] > > Collected errors: > * satisfy_dependencies_for: Cannot satisfy the following dependencies > for kmod-ath10k-ct: > * iw I already mailed Jow today about the issue, as I think that there has been something strange going on at the buildbot in the last week. Somebody with access to the buildbot and file storage should maybe check things, what is happening. Several packages fail this style: "Could not generate file hash" or "This does not look like a tar archive" errors. including also base packages, e.g. iw, iwinfo, firewall, ... I am a bit unsure if that has already been fixed or not. Or if there is a buildslave-specific thing? E.g iw for mips_24kc: https://downloads.openwrt.org/snapshots/faillogs/mips_24kc/base/iw/tiny/compile.txt + curl -f --connect-timeout 20 --retry 5 --location --insecure https://cdn.kernel.org/pub/software/network/iw/iw-5.4.tar.xz % Total% Received % Xferd Average Speed TimeTime Time Current Dload Upload Total SpentLeft Speed 0 00 00 0 0 0 --:--:-- --:--:-- --:--:-- 0 0 00 00 0 0 0 --:--:-- 0:00:01 --:--:-- 0 9 133k9 135580 0 8897 0 0:00:15 0:00:01 0:00:14 8896 100 133k 100 133k0 0 87627 0 0:00:01 0:00:01 --:--:-- 87621 Could not generate file hash Makefile:72: recipe for target '/store/buildbot/slave/shared-workdir/build/sdk/dl/iw-5.4.tar.xz' failed make[3]: *** [/store/buildbot/slave/shared-workdir/build/sdk/dl/iw-5.4.tar.xz] Error 255 time: package/feeds/base/iw/tiny/compile#0.42#0.35#2.80 https://downloads.openwrt.org/snapshots/faillogs/arm_cortex-a15_neon-vfpv4/base/ /store/buildbot/slave/shared-workdir/build/sdk/staging_dir/host/bin/xzcat: /store/buildbot/slave/shared-workdir/build/sdk/dl/libubox-2020-02-27-7da66430.tar.xz: File format not recognized /store/buildbot/slave/shared-workdir/build/sdk/staging_dir/host/bin/tar: This does not look like a tar archive /store/buildbot/slave/shared-workdir/build/sdk/staging_dir/host/bin/tar: Exiting with failure status due to previous errors + curl -f --connect-timeout 20 --retry 5 --location --insecurehttp://www.draisberghof.de/usb_modeswitch/usb-modeswitch-data-20191128.tar.bz2 % Total% Received % Xferd Average Speed TimeTime Time Current Dload Upload Total SpentLeft Speed 0 00 00 0 0 0 --:--:-- --:--:-- --:--:-- 0 0 00 00 0 0 0 --:--:-- --:--:-- --:--:-- 0 0 2870 00 0 0 0 --:--:-- --:--:-- --:--:-- 0 0 00 00 0 0 0 --:--:-- 0:00:01 --:--:-- 0 100 34069 100 340690 0 16432 0 0:00:02 0:00:02 --:--:-- 272k Could not generate file hash Makefile:31: recipe for target '/store/buildbot/slave/shared-workdir/build/sdk/dl/usb-modeswitch-data-20191128.tar.bz2' failed make[3]: *** [/store/buildbot/slave/shared-workdir/build/sdk/dl/usb-modeswitch-data-20191128.tar.bz2] Error 255 time: package/feeds/base/usbmode/compile#0.66#0.90#5.59 ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH RFC v3] ath79: add support for the ar7240 version of the ubiquiti bullet
The Ubiquiti Bullet M2HP come in two flavors, based on ar7240 and ar7241. Both are supported by ar71xx, despite the different SoCs. The ath79 target, however, currently supports only the ar7241. The ar7240 version apparently has a differently wired ethernet interface and the ar7241-based image comes up on the ar7240-based versions without a working ethernet interface. This is an attempt to support both flavors of ubnt-bullet-m, separately. Changes since v2: * generified ar7241_ubnt_xm.dtsi into ar724x_ubnt_xm.dtsi and converted the ubnt_xm family of devicetree's to stack #includes rather than chain them in order to avoid massive duplication between ar7240 and ar7241. * fixed a broken reference to ar7241_ubnt_outdoor-xm.dtsi Changes since v1: * renamed -v0 and -v1 to -ar7240 and -ar7241, respectively, as suggested. * abstracted ar7241_ubnt_outdoor-xm.dtsi to ar724x_ubnt_outdoor-xm.dtsi, so that it could be shared between ar7240 and ar7241. Included the new ar724x file in the terminal dts files rather than chain them. Interested in feedback. Tested on the AR7240 flavor. Signed-off-by: Russell Senior --- .../ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts | 22 +++ .../linux/ath79/dts/ar7241_ubnt_airrouter.dts | 3 ++- .../ath79/dts/ar7241_ubnt_bullet-m-ar7241.dts | 15 + .../linux/ath79/dts/ar7241_ubnt_bullet-m.dts | 13 --- .../dts/ar7241_ubnt_nanostation-loco-m.dts| 4 +++- .../ath79/dts/ar7241_ubnt_nanostation-m.dts | 4 +++- .../ath79/dts/ar7241_ubnt_picostation-m.dts | 4 +++- .../linux/ath79/dts/ar7241_ubnt_rocket-m.dts | 4 +++- ...r7241_ubnt_xm.dtsi => ar724x_ubnt_xm.dtsi} | 5 - ...tdoor.dtsi => ar724x_ubnt_xm_outdoor.dtsi} | 2 -- .../generic/base-files/etc/board.d/01_leds| 3 ++- .../generic/base-files/etc/board.d/02_network | 3 ++- .../etc/hotplug.d/firmware/10-ath9k-eeprom| 3 ++- target/linux/ath79/image/generic-ubnt.mk | 17 ++ 14 files changed, 70 insertions(+), 32 deletions(-) create mode 100644 target/linux/ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts create mode 100644 target/linux/ath79/dts/ar7241_ubnt_bullet-m-ar7241.dts delete mode 100644 target/linux/ath79/dts/ar7241_ubnt_bullet-m.dts rename target/linux/ath79/dts/{ar7241_ubnt_xm.dtsi => ar724x_ubnt_xm.dtsi} (92%) rename target/linux/ath79/dts/{ar7241_ubnt_xm_outdoor.dtsi => ar724x_ubnt_xm_outdoor.dtsi} (94%) diff --git a/target/linux/ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts b/target/linux/ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts new file mode 100644 index 00..99bf971eec --- /dev/null +++ b/target/linux/ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts @@ -0,0 +1,22 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT +/dts-v1/; + +#include "ar7240.dtsi" +#include "ar724x_ubnt_xm.dtsi" +#include "ar724x_ubnt_xm_outdoor.dtsi" + +/ { + compatible = "ubnt,bullet-m-ar7240", "ubnt,xm", "qca,ar7240"; + model = "Ubiquiti Bullet M AR7240"; +}; + + { + fixed-link { + speed = <100>; + full-duplex; + }; +}; + + { + compatible = "syscon", "simple-mfd"; +}; diff --git a/target/linux/ath79/dts/ar7241_ubnt_airrouter.dts b/target/linux/ath79/dts/ar7241_ubnt_airrouter.dts index ad2762e20c..dd2421da8e 100644 --- a/target/linux/ath79/dts/ar7241_ubnt_airrouter.dts +++ b/target/linux/ath79/dts/ar7241_ubnt_airrouter.dts @@ -1,7 +1,8 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "ar7241_ubnt_xm.dtsi" +#include "ar7241.dtsi" +#include "ar724x_ubnt_xm.dtsi" / { compatible = "ubnt,airrouter", "ubnt,xm", "qca,ar7241"; diff --git a/target/linux/ath79/dts/ar7241_ubnt_bullet-m-ar7241.dts b/target/linux/ath79/dts/ar7241_ubnt_bullet-m-ar7241.dts new file mode 100644 index 00..bb0f19c9eb --- /dev/null +++ b/target/linux/ath79/dts/ar7241_ubnt_bullet-m-ar7241.dts @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT +/dts-v1/; + +#include "ar7241.dtsi" +#include "ar724x_ubnt_xm.dtsi" +#include "ar724x_ubnt_xm_outdoor.dtsi" + +/ { + compatible = "ubnt,bullet-m-ar7241", "ubnt,xm", "qca,ar7241"; + model = "Ubiquiti Bullet M AR7241"; +}; + + { + compatible = "syscon", "simple-mfd"; +}; diff --git a/target/linux/ath79/dts/ar7241_ubnt_bullet-m.dts b/target/linux/ath79/dts/ar7241_ubnt_bullet-m.dts deleted file mode 100644 index e16b5fa0be..00 --- a/target/linux/ath79/dts/ar7241_ubnt_bullet-m.dts +++ /dev/null @@ -1,13 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0-or-later OR MIT -/dts-v1/; - -#include "ar7241_ubnt_xm_outdoor.dtsi" - -/ { - compatible = "ubnt,bullet-m", "ubnt,xm", "qca,ar7241"; - model = "Ubiquiti Bullet M"; -}; - - { - compatible = "syscon", "simple-mfd"; -}; diff --git a/target/linux/ath79/dts/ar7241_ubnt_nanostation-loco-m.dts b/target/linux/ath79/dts/ar7241_ubnt_nanostation-loco-m.dts index 386b7c7073..60d5a21a22 100644 ---
Re: [OpenWrt-Devel] [PATCH RFC v2] ath79: add support for the ar7240 version of the ubiquiti bullet
This is actually broken in a few minor ways. I'll be following up with a fixed up v3 shortly. On Sat, Feb 29, 2020 at 3:36 AM Russell Senior wrote: > > The Ubiquiti Bullet M2HP come in two flavors, based on ar7240 and > ar7241. Both are supported by ar71xx, despite the different SoCs. The > ath79 target, however, currently supports only the ar7241. The ar7240 > version apparently has a differently wired ethernet interface and the > ar7241-based image comes up on the ar7240-based versions without a > working ethernet interface. > > This is an attempt to support both flavors of ubnt-bullet-m, > separately. > > Changes since v1: > > * renamed -v0 and -v1 to -ar7240 and -ar7241, respectively, as > suggested. > > * abstracted ar7241_ubnt_outdoor-xm.dtsi to ar724x_ubnt_outdoor-xm.dtsi, > so that it could be shared between ar7240 and ar7241. Included the new > ar724x file in the terminal dts files rather than chain them. > > > There is a further opportunity to share a > target/linux/ath79/dts/ar724x_ubnt_xm.dtsi file, as > target/linux/ath79/dts/ar7240_ubnt_xm.dtsi and > target/linux/ath79/dts/ar7241_ubnt_xm.dtsi differ in one line only. > > Interested in feedback. > > Tested on the AR7240 flavor. > > Signed-off-by: Russell Senior > > > --- > .../ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts | 21 > target/linux/ath79/dts/ar7240_ubnt_xm.dtsi| 99 +++ > ...-m.dts => ar7241_ubnt_bullet-m-ar7241.dts} | 1 + > ...tdoor.dtsi => ar724x_ubnt_xm_outdoor.dtsi} | 2 - > .../generic/base-files/etc/board.d/01_leds| 3 +- > .../generic/base-files/etc/board.d/02_network | 3 +- > .../etc/hotplug.d/firmware/10-ath9k-eeprom| 3 +- > target/linux/ath79/image/generic-ubnt.mk | 17 +++- > 8 files changed, 140 insertions(+), 9 deletions(-) > create mode 100644 target/linux/ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts > create mode 100644 target/linux/ath79/dts/ar7240_ubnt_xm.dtsi > rename target/linux/ath79/dts/{ar7241_ubnt_bullet-m.dts => > ar7241_ubnt_bullet-m-ar7241.dts} (88%) > rename target/linux/ath79/dts/{ar7241_ubnt_xm_outdoor.dtsi => > ar724x_ubnt_xm_outdoor.dtsi} (94%) > > diff --git a/target/linux/ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts > b/target/linux/ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts > new file mode 100644 > index 00..5fb24b36c8 > --- /dev/null > +++ b/target/linux/ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts > @@ -0,0 +1,21 @@ > +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT > +/dts-v1/; > + > +#include "ar7240_ubnt_xm.dtsi" > +#include "ar724x_ubnt_xm_outdoor.dtsi" > + > +/ { > + compatible = "ubnt,bullet-m-ar7240", "ubnt,xm", "qca,ar7240"; > + model = "Ubiquiti Bullet M AR7240"; > +}; > + > + { > + fixed-link { > + speed = <100>; > + full-duplex; > + }; > +}; > + > + { > + compatible = "syscon", "simple-mfd"; > +}; > diff --git a/target/linux/ath79/dts/ar7240_ubnt_xm.dtsi > b/target/linux/ath79/dts/ar7240_ubnt_xm.dtsi > new file mode 100644 > index 00..7165ce5668 > --- /dev/null > +++ b/target/linux/ath79/dts/ar7240_ubnt_xm.dtsi > @@ -0,0 +1,99 @@ > +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT > + > +#include > +#include > + > +#include "ar7240.dtsi" > + > +/ { > + compatible = "ubnt,xm", "qca,ar7240"; > + model = "Ubiquiti Networks XM (rev 1.0) board"; > + > + keys { > + compatible = "gpio-keys"; > + > + reset { > + linux,code = ; > + gpios = < 12 GPIO_ACTIVE_LOW>; > + debounce-interval = <60>; > + }; > + }; > +}; > + > + { > + status = "okay"; > +}; > + > + { > + status = "okay"; > + > + num-cs = <1>; > + > + flash@0 { > + compatible = "jedec,spi-nor"; > + reg = <0>; > + spi-max-frequency = <2500>; > + > + partitions { > + compatible = "fixed-partitions"; > + #address-cells = <1>; > + #size-cells = <1>; > + > + partition@0 { > + label = "u-boot"; > + reg = <0x00 0x04>; > + read-only; > + }; > + > + partition@4 { > + label = "u-boot-env"; > + reg = <0x04 0x01>; > + }; > + > + partition@5 { > + compatible = "denx,uimage"; > + label = "firmware"; > + reg = <0x05 0x75>; > + }; > + > + partition@7a { > + label = "board_config"; > + reg = <0x7a 0x01>; > + read-only; > +
[OpenWrt-Devel] ImageBuilder: satisfy_dependencies_for [...] iw
Hi, for the last few days I get the following error for multiple targets, would it be possible to rerun the snapshot servers to rebuild the package `iw`? $ make manifest PROFILE="devolo_dvl1750e" [...] Collected errors: * satisfy_dependencies_for: Cannot satisfy the following dependencies for kmod-ath10k-ct: * iw * opkg_install_cmd: Cannot install package kmod-ath10k-ct. make[2]: *** [Makefile:157: package_install] Error 255 make[1]: *** [Makefile:127: _call_manifest] Error 2 make: *** [Makefile:207: manifest] Error 2 Thanks, Paul ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH RFC v2] ath79: add support for the ar7240 version of the ubiquiti bullet
The Ubiquiti Bullet M2HP come in two flavors, based on ar7240 and ar7241. Both are supported by ar71xx, despite the different SoCs. The ath79 target, however, currently supports only the ar7241. The ar7240 version apparently has a differently wired ethernet interface and the ar7241-based image comes up on the ar7240-based versions without a working ethernet interface. This is an attempt to support both flavors of ubnt-bullet-m, separately. Changes since v1: * renamed -v0 and -v1 to -ar7240 and -ar7241, respectively, as suggested. * abstracted ar7241_ubnt_outdoor-xm.dtsi to ar724x_ubnt_outdoor-xm.dtsi, so that it could be shared between ar7240 and ar7241. Included the new ar724x file in the terminal dts files rather than chain them. There is a further opportunity to share a target/linux/ath79/dts/ar724x_ubnt_xm.dtsi file, as target/linux/ath79/dts/ar7240_ubnt_xm.dtsi and target/linux/ath79/dts/ar7241_ubnt_xm.dtsi differ in one line only. Interested in feedback. Tested on the AR7240 flavor. Signed-off-by: Russell Senior --- .../ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts | 21 target/linux/ath79/dts/ar7240_ubnt_xm.dtsi| 99 +++ ...-m.dts => ar7241_ubnt_bullet-m-ar7241.dts} | 1 + ...tdoor.dtsi => ar724x_ubnt_xm_outdoor.dtsi} | 2 - .../generic/base-files/etc/board.d/01_leds| 3 +- .../generic/base-files/etc/board.d/02_network | 3 +- .../etc/hotplug.d/firmware/10-ath9k-eeprom| 3 +- target/linux/ath79/image/generic-ubnt.mk | 17 +++- 8 files changed, 140 insertions(+), 9 deletions(-) create mode 100644 target/linux/ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts create mode 100644 target/linux/ath79/dts/ar7240_ubnt_xm.dtsi rename target/linux/ath79/dts/{ar7241_ubnt_bullet-m.dts => ar7241_ubnt_bullet-m-ar7241.dts} (88%) rename target/linux/ath79/dts/{ar7241_ubnt_xm_outdoor.dtsi => ar724x_ubnt_xm_outdoor.dtsi} (94%) diff --git a/target/linux/ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts b/target/linux/ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts new file mode 100644 index 00..5fb24b36c8 --- /dev/null +++ b/target/linux/ath79/dts/ar7240_ubnt_bullet-m-ar7240.dts @@ -0,0 +1,21 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT +/dts-v1/; + +#include "ar7240_ubnt_xm.dtsi" +#include "ar724x_ubnt_xm_outdoor.dtsi" + +/ { + compatible = "ubnt,bullet-m-ar7240", "ubnt,xm", "qca,ar7240"; + model = "Ubiquiti Bullet M AR7240"; +}; + + { + fixed-link { + speed = <100>; + full-duplex; + }; +}; + + { + compatible = "syscon", "simple-mfd"; +}; diff --git a/target/linux/ath79/dts/ar7240_ubnt_xm.dtsi b/target/linux/ath79/dts/ar7240_ubnt_xm.dtsi new file mode 100644 index 00..7165ce5668 --- /dev/null +++ b/target/linux/ath79/dts/ar7240_ubnt_xm.dtsi @@ -0,0 +1,99 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT + +#include +#include + +#include "ar7240.dtsi" + +/ { + compatible = "ubnt,xm", "qca,ar7240"; + model = "Ubiquiti Networks XM (rev 1.0) board"; + + keys { + compatible = "gpio-keys"; + + reset { + linux,code = ; + gpios = < 12 GPIO_ACTIVE_LOW>; + debounce-interval = <60>; + }; + }; +}; + + { + status = "okay"; +}; + + { + status = "okay"; + + num-cs = <1>; + + flash@0 { + compatible = "jedec,spi-nor"; + reg = <0>; + spi-max-frequency = <2500>; + + partitions { + compatible = "fixed-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + partition@0 { + label = "u-boot"; + reg = <0x00 0x04>; + read-only; + }; + + partition@4 { + label = "u-boot-env"; + reg = <0x04 0x01>; + }; + + partition@5 { + compatible = "denx,uimage"; + label = "firmware"; + reg = <0x05 0x75>; + }; + + partition@7a { + label = "board_config"; + reg = <0x7a 0x01>; + read-only; + }; + + partition@7b { + label = "cfg"; + reg = <0x7b 0x04>; + read-only; + }; + + art: partition@7f { + label = "art"; + reg = <0x7f 0x01>; +