openwrt/staging/nbd.git
3 years agompc85xx: refresh kernel config
Pawel Dembicki [Sun, 10 Jan 2021 20:12:44 +0000 (21:12 +0100)]
mpc85xx: refresh kernel config

Simple "make kernel_oldconfig" was done.

Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
3 years agotreewide: unify OpenWrt hosted source via @OPENWRT
Paul Spooren [Sat, 30 Jan 2021 20:54:44 +0000 (10:54 -1000)]
treewide: unify OpenWrt hosted source via @OPENWRT

Multiple sources are hosted on OpenWrts source server only. The source
URLs to point to the server vary based on different epochs in OpenWrts
history.

Replace all by @OPENWRT which is an "empty" mirror, therefore using the
fallback servers sources.cdn.openwrt.org and sources.openwrt.org.

Signed-off-by: Paul Spooren <mail@aparcar.org>
3 years agokirkwood: use 3 temperature sensors for Zyxel NSA310B
Thomas Beckler [Sat, 30 May 2020 21:40:03 +0000 (23:40 +0200)]
kirkwood: use 3 temperature sensors for Zyxel NSA310B

Instead of taking the input of one temperature sensor (temp1), the
script takes into account three temperature sensors to control the
PWM of the cooling fan.

temp1 -> placed on main board
temp2 -> placed on main board
temp3 -> placed on or close to chipset

All three temperatures give valid input for the PWM of the fan on
NSA310 and are actually changing.

Tested on two NSA310.

Signed-off-by: Thomas Beckler <thomas.beckler@hotmail.com>
Reviewed-by: Alberto Bursi <bobafetthotmail@gmail.com>
[commit title/message facelift, code cleanup]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agotplink-safeloader: add support for TP-Link Archer A7 v5 (RU)
Alexey Kunitskiy [Sun, 13 Dec 2020 16:48:58 +0000 (18:48 +0200)]
tplink-safeloader: add support for TP-Link Archer A7 v5 (RU)

Although provided in separate zip archives, the firmwares for EU
and RU version are byte-identical. This adds the missing ID compared
to the support-list in the vendor firmware.

Note (since I checked it anyway):

Partitions and support list are unchanged for all three existing
firmware versions:

  * 20200721-rel40773
  * 20201029-rel43238
  * 20201120-rel50399

Signed-off-by: Alexey Kunitskiy <alexey.kv@gmail.com>
[rewrite commit message]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agoath79: wrap ucidef_add_switch in 02_network
Adrian Schmutzler [Fri, 5 Feb 2021 19:53:26 +0000 (20:53 +0100)]
ath79: wrap ucidef_add_switch in 02_network

Wrap line to be consistent with all other definitions.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agobuild: move elx-header into image-commands.mk
Yanase Yuki [Thu, 5 Nov 2020 10:59:06 +0000 (19:59 +0900)]
build: move elx-header into image-commands.mk

ELECOM WAB-I1750-PS will need this in ath79, so move it to common
Makefile.

Signed-off-by: Yanase Yuki <dev@zpc.sakura.ne.jp>
3 years agokirkwood: refresh kernel config
Sungbo Eo [Fri, 25 Dec 2020 11:16:41 +0000 (20:16 +0900)]
kirkwood: refresh kernel config

Refresh config with make kernel_oldconfig.

Signed-off-by: Sungbo Eo <mans0n@gorani.run>
3 years agolantiq: change phy-mode to mii for FRITZ!Box 7412
Aleksander Jan Bajkowski [Tue, 3 Nov 2020 20:29:21 +0000 (21:29 +0100)]
lantiq: change phy-mode to mii for FRITZ!Box 7412

FRITZ!Box 7412 loads the firmware for fast ethernet PHY and mii is
more accurate in this case.
Gmii is used by Gigabit ethernet PHYs.

Signed-off-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl>
Reviewed-by: Mathias Kresin <dev@kresin.me>
[minor commit title/message adjustments]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agoipq806x: replace full-text BSC license by SPDX identifier
Adrian Schmutzler [Fri, 5 Feb 2021 17:28:30 +0000 (18:28 +0100)]
ipq806x: replace full-text BSC license by SPDX identifier

This replaces a full-text BSD clause by the corresponding SPDX
identifier.

This should make it easier to identify the license both by humans
and machines.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agoramips: replace full-text licenses by SPDX identifier
Adrian Schmutzler [Fri, 5 Feb 2021 17:18:00 +0000 (18:18 +0100)]
ramips: replace full-text licenses by SPDX identifier

This replaces several full-text and abbreviated licenses found in
DTS files by the corresponding SPDX identifiers.

This should make it easier to identify the license both by humans
and machines.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agoramips: add support for UniElec U7621-01
David Bentham [Sat, 21 Nov 2020 14:04:49 +0000 (14:04 +0000)]
ramips: add support for UniElec U7621-01

UniElec U7621-01 is a router platform board, the smaller model of
the U7621-06.
The device has the following specifications:

- MT7621AT (880 MHz)
- 256 of RAM (DDR3)
- 16 MB of FLASH (SPI NOR)
- 5x 1 Gbps Ethernet (MT7621 built-in switch)
- 1x 2.4Ghz MT7603E
- 1x 5Ghz MT7612
- 1x miniPCIe slots (PCIe bus only)
- 1x miniSIM slot
- 1x USB 2.0 (uses the usb 3.0 driver)
- 8x LEDs (1x GPIO-controlled)
- 1x reset button
- 1x UART header (4-pins)
- 1x GPIO header (30-pins)
- 1x DC jack for main power (12 V)

The following has been tested and is working:

- Ethernet switch
- 1x 2.4Ghz MT7603E (wifi)
- 1x 5Ghz MT7612 (wifi)
- miniPCIe slots (tested with Wi-Fi cards and LTE modem cards)
- miniSIM slot (works with normal size simcard)
- sysupgrade
- reset button

Installation:

This board has no locked down bootloader. The seller can be asked to
install openwrt v18.06, so upgrades are standard sysupgrade method.

Recovery:

This board contains a Chinese, closed-source bootloader called Breed
(Boot and Recovery Environment for Embedded Devices). Breed supports web
recovery and to enter it, you keep the reset button pressed for around
5 seconds during boot. Your machine will be assigned an IP through DHCP
and the router will use IP address 192.168.1.1. The recovery website is
in Chinese, but is easy to use. Click on the second item in the list to
access the recovery page, then the second item on the next page is where
you select the firmware. In order to start the recovery, you click the
button at the bottom.

LEDs list (left to right):

- ESW_P0_LED_0
- ESW_P1_LED_0
- ESW_P2_LED_0
- ESW_P3_LED_0
- ESW_P4_LED_0
- CTS2_N (GPIO10, configured as "status" LED)
- LED_WLAN# (connected with pin 44 in wifi1 slot)

Signed-off-by: David Bentham <db260179@gmail.com>
[add DEVICE_VARIANT, fix DEVICE_PACKAGES, remove &gpio]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agoath79: add support for Meraki MR12
Martin Kennedy [Sat, 28 Nov 2020 02:03:32 +0000 (02:03 +0000)]
ath79: add support for Meraki MR12

Port device support for Meraki MR12 from the ar71xx target to ath79.

Specifications:

  - SoC: AR7242-AH1A CPU
  - RAM: 64MiB (NANYA NT5DS32M16DS-5T)
  - NOR Flash: 16MiB (MXIC MX25L12845EMI-10G)
  - Ethernet: 1 x PoE Gigabit Ethernet Port (SoC MAC + AR8021-BL1E PHY)
  - Ethernet: 1 x 100Mbit port (SoC MAC+PHY)
  - Wi-Fi: Atheros AR9283-AL1A (2T2R, 11n)

Installation:

  1. Requires TFTP server at 192.168.1.101, w/ initramfs & sysupgrade .bins
  2. Open shell case
  3. Connect a USB->TTL cable to headers furthest from the RF shield
  4. Power on the router; connect to U-boot over 115200-baud connection
  5. Interrupt U-boot process to boot Openwrt by running:
       setenv bootcmd bootm 0xbf0a0000; saveenv;
       tftpboot 0c00000 <filename-of-initramfs-kernel>.bin;
       bootm 0c00000;
  6. Copy sysupgrade image to /tmp on MR12
  7. sysupgrade /tmp/<filename-of-sysupgrade>.bin

Notes:

  - kmod-owl-loader is still required to load the ART partition into the
    driver.

  - The manner of storing MAC addresses is updated from ar71xx; it is
    at 0x66 of the 'config' partition, where it was discovered that the
    OEM firmware stores it. This is set as read-only. If you are
    migrating from ar71xx and used the method mentioned above to
    upgrade, use kmod-mtd-rw or UCI to add the MAC back in. One more
    method for doing this is described below.

  - Migrating directly from ar71xx has not been thoroughly tested, but
    one method has been used a couple of times with good success,
    migrating 18.06.2 to a full image produced as of this commit. Please
    note that these instructions are only for experienced users, and/or
    those still able to open their device up to flash it via the serial
    headers should anything go wrong.

    1) Install kmod-mtd-rw and uboot-envtools
    2) Run `insmod mtd-rw.ko i_want_a_brick=1`
    3) Modify /etc/fw_env.config to point to the u-boot-env partition.
       The file /etc/fw_env.config should contain:

       # MTD device   env offset  env size    sector size
       /dev/mtd1      0x00000     0x10000     0x10000

       See https://openwrt.org/docs/techref/bootloader/uboot.config
       for more details.

    4) Run `fw_printenv` to verify everything is correct, as per the
       link above.
    5) Run `fw_setenv bootcmd bootm 0xbf0a0000` to set a new boot address.
    6) Manually modify /lib/upgrade/common.sh's get_image function:
       Change ...

       cat "$from" 2>/dev/null | $cmd

       ... into ...

       (
         dd if=/dev/zero bs=1 count=$((0x66)) ; # Pad the first 102 bytes
         echo -ne '\x00\x18\x0a\x12\x34\x56'  ; # Add in MAC address
         dd if=/dev/zero bs=1 count=$((0x20000-0x66-0x6)) ; # Pad the rest
         cat "$from" 2>/dev/null
       ) | $cmd

       ... which, during the upgrade process, will pad the image by
       128K of zeroes-plus-MAC-address, in order for the ar71xx's
       firmware partition -- which starts at 0xbf080000 -- to be
       instead aligned with the ath79 firmware partition, which
       starts 128K later at 0xbf0a0000.

    7) Copy the sysupgrade image into /tmp, as above
    8) Run `sysupgrade -F /tmp/<sysupgrade>.bin`, then wait

    Again, this may BRICK YOUR DEVICE, so make *sure* to have your
    serial cable handy.

Signed-off-by: Martin Kennedy <hurricos@gmail.com>
[add LED migration and extend compat message]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agoramips: add support for Hi-Link HLK-7688A
Ewan Parker [Sat, 31 Oct 2020 09:29:54 +0000 (09:29 +0000)]
ramips: add support for Hi-Link HLK-7688A

Specifications:

  - SoC: MediaTek MT7688AN
  - RAM: 128 MB
  - Flash: 32 MB
  - Ethernet: 5x 10/100 (1x WAN, 4x LAN)
  - Wireless: built in 2.4GHz (bgn)
  - USB: 1x USB 2.0 port
  - Buttons: 1x Reset
  - LEDs: 1x (WiFi)

Flash instructions:

  - Configure TFTP server with IP address 10.10.10.3
  - Name the firmware file as firmware.bin
  - Connect any Ethernet port to the TFTP server's LAN
  - Choose option 2 in U-Boot
  - Alternatively choose option 7 to upload firmware to the built-in
    web server

MAC addresses as verified by OEM firmware:

  use   address   source
  2g    *:XX      factory 0x4
  LAN   *:XX+1    factory 0x28
  WAN   *:XX+1    factory 0x2e

Notes:

This board is ostensibly a module containing the MediaTek MT7688AN SoC,
128 MB DDR2 SDRAM and 32 MB flash storage.  The SoC can be operated in
IoT Gateway Mode or IoT Device Mode.

From some vendors the U-Boot that comes installed operates on UART 2
which is inaccessible in gateway mode and operates unreliably in the
Linux kernel when using more than 64 MB of RAM.  For those, updating
U-Boot is recommended.

Signed-off-by: Ewan Parker <ewan@ewan.cc>
[add WLAN to 01_leds]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agobuild: use SPDX license tags
Paul Spooren [Tue, 22 Sep 2020 02:48:37 +0000 (16:48 -1000)]
build: use SPDX license tags

The license folder is a core part of OpenWrt and all GPL-2.0 licensed.
Use SPDX license tags to allow machines to check licenses.

Signed-off-by: Paul Spooren <mail@aparcar.org>
[rebase, keep some Copyright lines, sharpen commit message]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agoselinux-policy: update to version 0.6
Daniel Golle [Fri, 5 Feb 2021 13:16:21 +0000 (13:16 +0000)]
selinux-policy: update to version 0.6

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
3 years agokernel: add defaults for new SELinux options
Daniel Golle [Tue, 2 Feb 2021 12:56:16 +0000 (12:56 +0000)]
kernel: add defaults for new SELinux options

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
3 years agokernel: bump 5.4 to 5.4.95
John Audia [Thu, 4 Feb 2021 02:09:56 +0000 (21:09 -0500)]
kernel: bump 5.4 to 5.4.95

Ran update_kernel.sh in a fresh clone without any existing toolchains.

Removed upstreamed patches:
 imx6: 303-ARM-dts-imx6qdl-gw52xx-fix-duplicate-regulator-namin.patch

Build system: x86_64
Build-tested: ipq806x/R7800, bcm27xx/bcm2711
Run-tested: ipq806x/R7800

No dmesg regressions, everything functional

Signed-off-by: John Audia <graysky@archlinux.us>
3 years agohostapd: add forgotten patch for P2P vulnerability fix
Petr Štetiar [Thu, 4 Feb 2021 08:10:05 +0000 (09:10 +0100)]
hostapd: add forgotten patch for P2P vulnerability fix

Commit 7c8c4f1be648 ("hostapd: fix P2P group information processing
vulnerability") was missing the actual patch for the vulnerability.

Fixes: 7c8c4f1be648 ("hostapd: fix P2P group information processing vulnerability")
Signed-off-by: Petr Štetiar <ynezz@true.cz>
3 years agohostapd: fix P2P group information processing vulnerability
Daniel Golle [Thu, 4 Feb 2021 01:01:36 +0000 (01:01 +0000)]
hostapd: fix P2P group information processing vulnerability

A vulnerability was discovered in how wpa_supplicant processing P2P
(Wi-Fi Direct) group information from active group owners.
This issue was discovered by fuzz testing of wpa_supplicant by Google's
OSS-Fuzz.

https://w1.fi/security/2020-2/wpa_supplicant-p2p-group-info-processing-vulnerability.txt

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
3 years agotrusted-firmware-a.mk: add PKG_CPE_ID
Daniel Golle [Wed, 3 Feb 2021 15:38:14 +0000 (15:38 +0000)]
trusted-firmware-a.mk: add PKG_CPE_ID

Vulnerabilities of Trusted Firmware A are tracked as
cpe:/a:arm:arm_trusted_firmware

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
3 years agoarm-trusted-firmware-mediatek: make use of trusted-firmware-a.mk
Daniel Golle [Wed, 3 Feb 2021 14:48:45 +0000 (14:48 +0000)]
arm-trusted-firmware-mediatek: make use of trusted-firmware-a.mk

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
3 years agotfa-layerscape: don't build fiptool
Daniel Golle [Wed, 3 Feb 2021 14:42:51 +0000 (14:42 +0000)]
tfa-layerscape: don't build fiptool

tfa-fiptool is now provided by an extra package. Use that instead.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
3 years agoarm-trusted-firmware-tools: add package
Daniel Golle [Wed, 3 Feb 2021 14:41:50 +0000 (14:41 +0000)]
arm-trusted-firmware-tools: add package

Package ARM Trusted Firmware host tools separately.
(instead of building tfa-fiptool as part of tfa-layerscape)

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
3 years agoiptables: update to 1.8.7
Curtis Deptuck [Mon, 1 Feb 2021 21:03:47 +0000 (14:03 -0700)]
iptables: update to 1.8.7

ChangeLog:
https://netfilter.org/projects/iptables/files/changes-iptables-1.8.7.txt

Refresh patch:
None required

Signed-off-by: Curtis Deptuck <curtdept@me.com>
3 years agobcm63xx: sprom: override the PCI device ID
Daniel González Cabanelas [Tue, 2 Feb 2021 11:11:09 +0000 (12:11 +0100)]
bcm63xx: sprom: override the PCI device ID

The PCI device ID detected by the wifi drivers on devices using a fallback
SPROM is wrong. Currently the chipnum is used for this parameter.

Most SSB based Broadcom wifi chips are 2.4 and 5GHz capable. But on
devices without a physical SPROM, the only one way to detect if the device
suports both bands or only the 5GHz band, is by reading the device ID from
the fallback SPROM.

In some devices, this may lead to a non working wifi on a 5GHz-only card,
or in the best case a working 2.4GHz-only in a dual band wifi card.

The offset for the deviceid in SSB SPROMs is 0x0008, whereas in BCMA is
0x0060. This is true for any SPROM version.

Override the PCI device ID with the one defined at the fallback SPROM, to
detect the correct wifi card model and allow using the 5GHz band if
supported.

The patch has been tested with the following wifi radios:

BCM43222: b43: both 2.4/5GHz working
          brcm-wl: both 2.4/5GHz working

BCM43225: b43: 2.4GHz, working
 brcmsmac: working
 brcm-wl: it lacks support

BCM43217: b43: 2.4GHz, working
 brcmsmac: it lacks support
 brcm-wl: it lacks support

Signed-off-by: Daniel González Cabanelas <dgcbueu@gmail.com>
[amend commit description, rework patch to avoid using a new global variable
and keep ssb sprom extraction code as close to ssb/pci.c as possible]
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
3 years agobcm63xx: backport upstream SSB SPROM extraction
Álvaro Fernández Rojas [Tue, 2 Feb 2021 10:02:39 +0000 (11:02 +0100)]
bcm63xx: backport upstream SSB SPROM extraction

New upstream changes extract more SPROM values and fix the antenna gain.
These changes can be found in linux drivers/ssb/pci.c.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
3 years agoarm-trusted-firmware-mediatek: add ATF builds for MT7622
Daniel Golle [Tue, 2 Feb 2021 18:04:33 +0000 (18:04 +0000)]
arm-trusted-firmware-mediatek: add ATF builds for MT7622

ATF bl2 comes in 4 variants for MT7622 depending on the boot media:
 * nor
 * snand
 * emmc
 * sdmmc

Additional binary headers needed for emmc and sdmmc are downloaded as
well and provided along with bl2*.bin and bl31.bin to allow building
images including ATF for MT7622.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
3 years agoprocd: update to git HEAD
Daniel Golle [Tue, 2 Feb 2021 13:28:09 +0000 (13:28 +0000)]
procd: update to git HEAD

 0aee1c3 hotplug.c: set nl_pid to zero
 d6dda31 procd: fix compiler warning
 92c8e8f jail: remove duplicate check for hook file permissions
 0a74c06 jail: only output BPF instr. table header if debugging
 fd18379 jail: cgroups: fix uninitialized variabl

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
3 years agokernel: bump 5.4 to 5.4.94
John Audia [Sat, 30 Jan 2021 14:37:13 +0000 (09:37 -0500)]
kernel: bump 5.4 to 5.4.94

All modification made by update_kernel.sh in a fresh clone without
existing toolchains.

Build-tested: bcm27xx/bcm2711, ipq806x/R7800,
Run-tested: ipq806x/R7800

No dmesg regressions, everything functional

Signed-off-by: John Audia <graysky@archlinux.us>
3 years agomac80211: fix station rate table updates on assoc
Felix Fietkau [Mon, 1 Feb 2021 08:59:49 +0000 (09:59 +0100)]
mac80211: fix station rate table updates on assoc

If the driver uses .sta_add, station entries are only uploaded after the sta
is in assoc state. Fix early station rate table updates by deferring them
until the sta has been uploaded

Signed-off-by: Felix Fietkau <nbd@nbd.name>
3 years agomac80211: fix incorrect parameter
David Bauer [Tue, 19 Jan 2021 01:36:14 +0000 (02:36 +0100)]
mac80211: fix incorrect parameter

he_mu_beamformer only accepts values of 0 and 1 according to the hostapd
documentation.

Signed-off-by: David Bauer <mail@david-bauer.net>
3 years agoath79: ag71xx: add ethtool statistics support
Leon Leijssen [Tue, 12 Jan 2021 09:56:36 +0000 (10:56 +0100)]
ath79: ag71xx: add ethtool statistics support

Add statistics to ethtool. The statistics can be useful to
debug network issues.

The code is backported from mainline ag71xx.c driver.

Signed-off-by: Leon Leijssen <leon.git@leijssen.info>
3 years agouboot-rockchip: fix RockPro64 boot from eMMC
Marty Jones [Sat, 23 Jan 2021 16:10:36 +0000 (11:10 -0500)]
uboot-rockchip: fix RockPro64 boot from eMMC

With upstream commit f81f9f0ebac5 ("rockchip: rockpro64: initialize USB in
preboot") CONFIG_USE_PREBOOT was enabled on the RockPro64, which is causing
boot issues when a eMMC is used, as a workaround will temporarily disable
this option.

Signed-off-by: Marty Jones <mj8263788@gmail.com>
[Improve patch description]
Signed-off-by: David Bauer <mail@david-bauer.net>
3 years agoath79: add support for Ubiquiti UniFi AP Outdoor+
David Bauer [Wed, 9 Dec 2020 21:18:43 +0000 (22:18 +0100)]
ath79: add support for Ubiquiti UniFi AP Outdoor+

Hardware
--------
Atheros AR7241
16M SPI-NOR
64M DDR2
Atheros AR9283 2T2R b/g/n
2x Fast Ethernet (built-in)

Installation
------------

Transfer the Firmware update to the device using SCP.

Install using fwupdate.real -m <openwrt.bin> -d

Signed-off-by: David Bauer <mail@david-bauer.net>
3 years agomac80211: convert UniFi Outdoor+ HSR support to OF
David Bauer [Thu, 7 Jan 2021 00:03:05 +0000 (01:03 +0100)]
mac80211: convert UniFi Outdoor+ HSR support to OF

Enable support for the Ubiquiti UniFi Outdoor+ RF filter via
device-tree. The old way of using platform data is not required anymore,
as it was only used on the now removed ar71xx target.

Signed-off-by: David Bauer <mail@david-bauer.net>
3 years agoutil-linux: remove custom pkgconfig patch
Rosen Penev [Thu, 28 Jan 2021 05:17:07 +0000 (21:17 -0800)]
util-linux: remove custom pkgconfig patch

Replace with sed as done elsewhere.

Fixes error with at least btrfs-progs:

Package '@LIBSELINUX@', required by 'mount', not found
Package '@LIBCRYPTSETUP@', required by 'mount', not foun

Signed-off-by: Rosen Penev <rosenp@gmail.com>
3 years agoselinux-policy: update to git tag v0.5
Daniel Golle [Sun, 31 Jan 2021 14:01:19 +0000 (14:01 +0000)]
selinux-policy: update to git tag v0.5

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
3 years agoglibc: update to latest 2.32 commit (bug 27256)
Hans Dedecker [Sun, 31 Jan 2021 11:13:14 +0000 (12:13 +0100)]
glibc: update to latest 2.32 commit (bug 27256)

760e1d2878 gconv: Fix assertion failure in ISO-2022-JP-3 module (bug 27256)

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
3 years agomvebu: omnia: make initramfs image usable out of the box
Petr Štetiar [Sat, 30 Jan 2021 12:32:43 +0000 (13:32 +0100)]
mvebu: omnia: make initramfs image usable out of the box

Currently it's not possible to boot the device with just initramfs image
without additional effort as the initramfs image doesn't contain device
tree.  Fix it by producing FIT based image which could be booted with
following commands:

 setenv bootargs earlyprintk console=ttyS0,115200
 tftpboot ${kernel_addr_r} openwrt-mvebu-cortexa9-cznic_turris-omnia-initramfs-kernel.bin
 bootm ${kernel_addr_r}

Acked-by: Klaus Kudielka <klaus.kudielka@gmail.com>
Reviewed-by: Tomasz Maciej Nowak <tmn505@gmail.com>
Signed-off-by: Petr Štetiar <ynezz@true.cz>
3 years agotools/zstd: compile with cmake
Rosen Penev [Thu, 21 Jan 2021 04:54:58 +0000 (20:54 -0800)]
tools/zstd: compile with cmake

It's faster and more reliable.

Removed ccache cmake build dependency as it's now implicit.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
3 years agotools/zstd: update to 1.4.8
Rosen Penev [Thu, 21 Jan 2021 04:54:57 +0000 (20:54 -0800)]
tools/zstd: update to 1.4.8

Switch to the normal tarball instead of the codeload generated one. The
latter has the potential to change hashes based on changes in the repo.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
3 years agorules: fix empty COMMITCOUNT/AUTORELEASE
Paul Spooren [Fri, 29 Jan 2021 09:17:10 +0000 (23:17 -1000)]
rules: fix empty COMMITCOUNT/AUTORELEASE

Packages that are in-tree only often lack a PKG_VERSION and only use the
PKG_RELEASE to mark changes. Using COMMITCOUNT/AUTORELEASE variables
causes an issue as both variables are empty during the metadata DUMP
phase.

Instead of leaving these variables empty and causing an error message
like below, set the variables to 0 during dumping. On actual building
the variable is evaluated causing in a value above 0.

ERROR: please fix package/utils/px5g-wolfssl/Makefile - \
see logs/package/utils/px5g-wolfssl/dump.txt for details

Makefile:48: *** Package/px5g-wolfssl is missing the VERSION field.  Stop.

Reported-by: Daniel Golle <daniel@makrotopia.org>
Reported-by: Stijn Segers <foss@volatilesystems.org>
Reported-by: Stijn Tintel <stijn@linux-ipv6.be>
Signed-off-by: Paul Spooren <mail@aparcar.org>
3 years agoodhcpd: update to latest git HEAD
Hans Dedecker [Sat, 30 Jan 2021 20:21:13 +0000 (21:21 +0100)]
odhcpd: update to latest git HEAD

8d8a8cd dhcpv6-ia: apply prefix_filter on dhcpv6

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
3 years agotrusted-firmware-a.mk: pass package version as version identifier
Andre Heider [Fri, 22 Jan 2021 13:44:08 +0000 (14:44 +0100)]
trusted-firmware-a.mk: pass package version as version identifier

Upon boot it now prints:
NOTICE:  BL1: v2.4(release):OpenWRT v2.4-1 (espressobin-v3-v5-1gb-2cs) (Marvell-devel-18.12.0)

Signed-off-by: Andre Heider <a.heider@gmail.com>
3 years agoarm-trusted-firmware-mvebu: pass commit ids to a3700-utils/mv-ddr-marvell
Andre Heider [Mon, 18 Jan 2021 15:54:26 +0000 (16:54 +0100)]
arm-trusted-firmware-mvebu: pass commit ids to a3700-utils/mv-ddr-marvell

The two required tools fail to identify their version when not compiling
from a git clone, patch that in and pass on the used commit hashes.

Upon boot it now prints "WTMI-devel-18.12.1-5598e150".

Signed-off-by: Andre Heider <a.heider@gmail.com>
3 years agoarm-trusted-firmware-mvebu: bump espressobin boards to CPU_1000_DDR_800
Andre Heider [Sun, 17 Jan 2021 07:38:53 +0000 (08:38 +0100)]
arm-trusted-firmware-mvebu: bump espressobin boards to CPU_1000_DDR_800

The cpufreq issue has been identified and a fix is in the process of beeing
upstreamed [0].

Bump the boards to the default 1000MHz so they can run at that frequency
once the fix is merged. Until then the boards are stuck at 800MHz (just
claiming to run 1000Hz, which is a lie).

[0] https://lore.kernel.org/linux-arm-kernel/20210114124032.12765-1-pali@kernel.org/

Signed-off-by: Andre Heider <a.heider@gmail.com>
3 years agoarm-trusted-firmware-mvebu: update to v2.4
Andre Heider [Sun, 17 Jan 2021 07:37:58 +0000 (08:37 +0100)]
arm-trusted-firmware-mvebu: update to v2.4

Signed-off-by: Andre Heider <a.heider@gmail.com>
3 years agouboot-mvebu: update to v2021.01
Andre Heider [Sun, 17 Jan 2021 07:35:32 +0000 (08:35 +0100)]
uboot-mvebu: update to v2021.01

u-boot now detects emmc variants at runtime, we don't need to build
seperate binaries anymore.

Signed-off-by: Andre Heider <a.heider@gmail.com>
3 years agoarm-trusted-firmware-mvebu: don't build emmc variants
Andre Heider [Sun, 17 Jan 2021 07:38:22 +0000 (08:38 +0100)]
arm-trusted-firmware-mvebu: don't build emmc variants

Starting with u-boot v2021.01 a single binary will be used for non-emmc
and emmc variants.

Signed-off-by: Andre Heider <a.heider@gmail.com>
3 years agomvebu: LS421DE: fix the thermal zones
Daniel González Cabanelas [Sun, 3 Jan 2021 21:32:59 +0000 (22:32 +0100)]
mvebu: LS421DE: fix the thermal zones

The thermal zones kernel documentation is misleading, we cannot use more
than one sensor in a thermal zone node.

Furthermore the drivetemp driver for some reason it only catches one
sensor from the hard drives array (the first available).

In the Buffalo Linkstation LS421DE board there is also a sensor at the
ethernet phy chip that can also be monitored. Very useful to stop the fan
when there are no hard drives in the bays.

(It might be also possible to add the CPU sensor, but it requires kernel
patching for registering the sensor via device tree, using the function:
devm_thermal_zone_of_sensor_register)

Fix the thermal zones to use only one sensor per node and add the ethernet
phy sensor. Also adjust the hdd temperatures to be more conservative for
a mechanical hard drive.

Signed-off-by: Daniel González Cabanelas <dgcbueu@gmail.com>
3 years agostrace: update package to v5.10
Geordan Neukum [Fri, 29 Jan 2021 18:59:04 +0000 (13:59 -0500)]
strace: update package to v5.10

v5.10 has been released for strace. As such, let's go ahead bring in the
latest version of this package.

See here for the changelog:
    https://github.com/strace/strace/releases/tag/v5.10

Signed-off-by: Geordan Neukum <gneukum1@gmail.com>
3 years agobase-files: mount pstore if present
Brian Norris [Sat, 23 Jan 2021 23:08:00 +0000 (15:08 -0800)]
base-files: mount pstore if present

Pstore (persistent store) can be used to stash debug information (kernel
console, panics, ftrace) across reboots or crashes. If the filesystem is
present, mount it.

Signed-off-by: Brian Norris <computersforpeace@gmail.com>
3 years agoath10k-ct: update to latest version
Michael Yartys [Fri, 22 Jan 2021 16:42:44 +0000 (17:42 +0100)]
ath10k-ct: update to latest version

Changelog:
- ath10k-ct: Pull in some upstream patches.

Runtime-tested on ipq806x (Netgear R7800).

Signed-off-by: Michael Yartys <michael.yartys@gmail.com>
3 years agoca-certicficates: Update to version 20210119
Paul Menzel [Thu, 21 Jan 2021 18:07:23 +0000 (19:07 +0100)]
ca-certicficates: Update to version 20210119

Update the ca-certificates and ca-bundle package from version 20200601 to
version 2021019.

This version uses Python 3 for the build, fixing a build issue on systems,
where `/usr/bin/python3` is a wrapper script [1].

Debian change-log entry [2]:

>   [ Julien Cristau ]
>   * New maintainer (closes: #976406)
>   * mozilla/{certdata.txt,nssckbi.h}: Update Mozilla certificate
> authority
>     bundle to version 2.46.
>     The following certificate authorities were added (+):
>     + "certSIGN ROOT CA G2"
>     + "e-Szigno Root CA 2017"
>     + "Microsoft ECC Root Certificate Authority 2017"
>     + "Microsoft RSA Root Certificate Authority 2017"
>     + "NAVER Global Root Certification Authority"
>     + "Trustwave Global Certification Authority"
>     + "Trustwave Global ECC P256 Certification Authority"
>     + "Trustwave Global ECC P384 Certification Authority"
>     The following certificate authorities were removed (-):
>     - "EE Certification Centre Root CA"
>     - "GeoTrust Universal CA 2"
>     - "LuxTrust Global Root 2"
>     - "OISTE WISeKey Global Root GA CA"
>     - "Staat der Nederlanden Root CA - G2" (closes: #962079)
>     - "Taiwan GRCA"
>     - "Verisign Class 3 Public Primary Certification Authority - G3"
>
>   [ Michael Shuler ]
>   * mozilla/blacklist:
>     Revert Symantec CA blacklist (#911289). Closes: #962596
>     The following root certificates were added back (+):
>     + "GeoTrust Primary Certification Authority - G2"
>     + "VeriSign Universal Root Certification Authority"
>
>   [ Gianfranco Costamagna ]
>   * debian/{rules,control}:
>     Merge Ubuntu patch from Matthias Klose to use Python3 during build.
>     Closes: #942915

[1]: https://github.molgen.mpg.de/mariux64/mxtools/issues/148
[2]: https://metadata.ftp-master.debian.org/changelogs//main/c/ca-certificates/ca-certificates_20210119_changelog

Signed-off-by: Paul Menzel <pmenzel@molgen.mpg.de>
3 years agoramips: add support for ELECOM WRC-2533GHBK-I
INAGAKI Hiroshi [Fri, 11 Dec 2020 14:14:58 +0000 (23:14 +0900)]
ramips: add support for ELECOM WRC-2533GHBK-I

ELECOM WRC-2533GHBK-I is a 2.4/5 GHz band 11ac (Wi-Fi 5) router, based
on MT7621A.

Specification:

- SoC : MediaTek MT7621A
- RAM : DDR3 128 MiB
- Flash : SPI-NOR 16 MiB
- WLAN : 2.4/5 GHz 4T4R (2x MediaTek MT7615)
- Ethernet : 10/100/1000 Mbps x5
  - Switch : MediaTek MT7530 (SoC)
- LED/keys : 4x/3x (2x buttons, 1x slide-switch)
- UART : through-hole on PCB
  - J4: 3.3V, RX, GND, TX from SoC side
  - 57600n8
- Power : 12VDC, 1.5A

Flash instruction using factory image:

1. Boot WRC-2533GHBK-I normally
2. Access to "http://192.168.2.1/" and open firmware update page
   ("ファームウェア更新")
3. Select the OpenWrt factory image and click apply ("適用") button
4. Wait ~150 seconds to complete flashing

MAC addresses:

LAN : BC:5C:4C:xx:xx:89 (Config, ethaddr (text))
WAN : BC:5C:4C:xx:xx:88 (Config, wanaddr (text))
2.4GHz : BC:5C:4C:xx:xx:8A (Factory, 0x4    (hex))
5GHz : BC:5C:4C:xx:xx:8B (Factory, 0x8004 (hex))

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
Reviewed-by: Sungbo Eo <mans0n@gorani.run>
3 years agobuild: add elecom-product-header for ELECOM devices
INAGAKI Hiroshi [Fri, 11 Dec 2020 14:14:03 +0000 (23:14 +0900)]
build: add elecom-product-header for ELECOM devices

A header used in ELECOM WRC-300GHBK2-I and WRC-1750GHBK2-I/C is also
used in ELECOM WRC-2533GHBK-I, so split the code to generate the header
and move it to image-commands.mk to use from ramips target.

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
Reviewed-by: Sungbo Eo <mans0n@gorani.run>
3 years agobase-files: remove execute bit and shebang from functions.sh
Adrian Schmutzler [Mon, 25 Jan 2021 11:48:43 +0000 (12:48 +0100)]
base-files: remove execute bit and shebang from functions.sh

/lib/functions.sh was executable for no obvious reason and its
execute property was even checked in package-ipkg.mk just to
source it afterwards.

Remove the execute bit and shebang as this is clearly a library.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Reviewed-by: Philip Prindeville <philipp@redfish-solutions.com>
3 years agotreewide: drop shebang from non-executable lib files
Adrian Schmutzler [Mon, 25 Jan 2021 11:48:42 +0000 (12:48 +0100)]
treewide: drop shebang from non-executable lib files

This drops the shebang from another bunch of files in various /lib
folders, as these are sourced and the shebang is useless.

Fix execute bit in one case, too.

This should cover almost all trivial cases now, i.e. where /lib is
actually used for library files.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agokernel: bump 5.4 to 5.4.93
John Audia [Wed, 27 Jan 2021 14:41:12 +0000 (09:41 -0500)]
kernel: bump 5.4 to 5.4.93

All modification made by update_kernel.sh in a fresh clone without
existing toolchains.

Build system:       x86_64
Build-tested:       ipq806x/R7800, bcm27xx/bcm2711
Run-tested:         ipq806x/R7800
Compile-tested [*]: ath79/{tiny,generic}, ipq40xx, octeon,
                    ramips/mt7621, realtek, x86/64
Run-tested [*]:     ath79/generic, ipq40xx, octeon, ramips/mt7621

No dmesg regressions, everything functional

Signed-off-by: John Audia <graysky@archlinux.us>
Tested-by: Stijn Segers <foss@volatilesystems.org> [*]
3 years agobcm63xx: fix bcm63xx ethernet kernel panics
Álvaro Fernández Rojas [Thu, 28 Jan 2021 10:49:16 +0000 (11:49 +0100)]
bcm63xx: fix bcm63xx ethernet kernel panics

Calling netdev_reset_queue() from _stop() functions is causing sporadic kernel
panics on bcm63xx, which happen mainly on BCM6318 and BCM6328.
This reverts to the previous behaviour, which called netdev_reset_queue() from
_open() functions.

Tested on Comtrend AR-5315u (BCM6318).

Fixes: 1d6f422e346b ("bcm63xx: sync ethernet driver with net-next")
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
3 years agoscripts: sources CDN as fallback in download.pl
Paul Spooren [Wed, 27 Jan 2021 04:13:28 +0000 (18:13 -1000)]
scripts: sources CDN as fallback in download.pl

In case the default sources for a package fail use the CDN rather than
our own mirror. In case the CDN fails, fallback to our mirror.

Also remove mirror1 which isn't available anymore.

Signed-off-by: Paul Spooren <mail@aparcar.org>
3 years agosunxi: add support for linksprite pcDuino3 nano board
Jiang Yongquan [Mon, 11 Jan 2021 15:09:23 +0000 (23:09 +0800)]
sunxi: add support for linksprite pcDuino3 nano board

Specifications:

 - SoC: Allwinner A20 @ 1Ghz
 - DRAM: 1GiB DDR3 @ 408MHz (K4B4G1646Q-HYK0)
 - NAND: 4GB MLC NAND (H27UBG8T2BTR-BC)
 - Ethernet: 10/100/1000Mbps Ethernet (Realtek RTL8211E)

Flash instructions:

dd if=openwrt-sunxi-cortexa7-linksprite_pcduino3-nano-ext4-sdcard.img
of=/dev/sdX

Signed-off-by: Jiang Yongquan <woxwchc@foxmail.com>
[Remove CONFIG_REALTEK_PHY from sunxi/cortexa53 config]
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
3 years agorockchip: fix SUPPORTED_DEVICES for Radxa ROCK Pi 4
Marty Jones [Mon, 25 Jan 2021 17:37:56 +0000 (12:37 -0500)]
rockchip: fix SUPPORTED_DEVICES for Radxa ROCK Pi 4

This sets SUPPORTED_DEVICES to match the compatible in the DTS.

While at it, synchronize the capitalization in DEVICE_MODEL and
DTS model.

Signed-off-by: Marty Jones <mj8263788@gmail.com>
[commit title/message facelift, move variable in armv8.mk]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agobcm4908: sort and wrap build recipes
Adrian Schmutzler [Sat, 23 Jan 2021 12:24:28 +0000 (13:24 +0100)]
bcm4908: sort and wrap build recipes

This sorts the Build recipes alphabetically, wraps some long lines
and moves the DEVICE_VARS to the top like common on several other
targets.

Cc: Rafał Miłecki <rafal@milecki.pl>
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
3 years agomediatek: remove generic profiles
Adrian Schmutzler [Fri, 22 Jan 2021 10:51:19 +0000 (11:51 +0100)]
mediatek: remove generic profiles

We have support for reference boards available on this target, so
support for an additional generic profile does not make much sense.

Remove it to have one thing less to maintain.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Acked-by: Paul Spooren <mail@aparcar.org>
3 years agokirkwood: remove generic profile
Adrian Schmutzler [Fri, 22 Jan 2021 10:48:12 +0000 (11:48 +0100)]
kirkwood: remove generic profile

On a platform with many very different devices, like found on kirkwood,
the generic profile seems like a remnant of the past that does not
have a real use anymore.

Remove it to have one thing less to maintain.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Acked-by: Paul Spooren <mail@aparcar.org>
3 years agoipq806x: remove generic profile
Adrian Schmutzler [Fri, 22 Jan 2021 10:47:35 +0000 (11:47 +0100)]
ipq806x: remove generic profile

On a platform with many very different devices, like found on ipq806x,
the generic profile seems like a remnant of the past that does not
have a real use anymore.

Remove it to have one thing less to maintain.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Acked-by: Paul Spooren <mail@aparcar.org>
3 years agoipq40xx: remove generic profile
Adrian Schmutzler [Fri, 22 Jan 2021 10:46:33 +0000 (11:46 +0100)]
ipq40xx: remove generic profile

On a platform with many very different devices, like found on ipq40xx,
the generic profile seems like a remnant of the past that does not
have a real use anymore.

Remove it to have one thing less to maintain.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Acked-by: Paul Spooren <mail@aparcar.org>
3 years agoramips: remove generic profiles
Adrian Schmutzler [Fri, 22 Jan 2021 10:45:03 +0000 (11:45 +0100)]
ramips: remove generic profiles

On a platform with many very different devices, like found on ramips,
the generic profiles seem like remnants of the past that do not
have a real use anymore.

Remove them to have one thing less to maintain.

Actually, rt288x didn't have a default profile in the first place.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Acked-by: Paul Spooren <mail@aparcar.org>
3 years agoath79: remove generic profiles
Adrian Schmutzler [Thu, 21 Jan 2021 19:37:55 +0000 (20:37 +0100)]
ath79: remove generic profiles

On a platform with many very different devices, like found on ath79,
the generic profiles seem like remnants of the past that do not
have a real use anymore.

Remove them to have one thing less to maintain.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Acked-by: Paul Spooren <mail@aparcar.org>
3 years agomt76: update to the latest version
Felix Fietkau [Wed, 27 Jan 2021 19:54:34 +0000 (20:54 +0100)]
mt76: update to the latest version

65abbcd9f6fb mt76: usb: process URBs with status EPROTO properly
3199ef5fa35e mt76: mt7615: set mcu country code in mt7615_mcu_set_channel_domain()
5c86d5bb079b mt76: mt7915: Remove unneeded semicolon
3f546330b59d mt76: mt7915: support TxBF for DBDC
032ad7e02545 mt76: mt7615: unify init work
cc3f23d1e654 mt76: mt7915: bring up the WA event rx queue for band1
fa3d334a0e22 mt76: fix crash on tearing down ext phy
c4c9c402d14a mt76: mt7915: fix vif sta index for DBDC
eca2f0ec0d4c mt76: mt7915: fix command id for txbf action
c828124ef9a5 mt76: mt7915: add support for using a secondary PCIe link for gen1
dbaf0f4679f3 mt76: mt7915: make vif index per adapter instead of per band
fb3e5ce1eb00 mt76: move vif_mask back from mt76_phy to mt76_dev
be2bea66d6e3 mt76: mt7915: detect wrong nss eeprom parameter on dbdc cards
8dc5d4a0da7c Revert "mt76: mt7915: fix vif sta index for DBDC"
8c796a33781c mt76: mt7915: only set int1 when using the second hif
4eb5caaf6cc1 mt76: reduce q->lock hold time
0714890bf0fd mt76: mt7615: reduce VHT maximum MPDU length
2f85aa5cbc62 mt76: mt7915: avoid writes to MT_PCIE_RECOG_ID when not using gen1 devices
8696919d9aae mt76: dma: fix a possible memory leak in mt76_add_fragment()

Signed-off-by: Felix Fietkau <nbd@nbd.name>
3 years agoramips: use lzma-loader on zbtlink devices
Felix Fietkau [Wed, 27 Jan 2021 12:26:23 +0000 (13:26 +0100)]
ramips: use lzma-loader on zbtlink devices

Fixes boot loader LZMA decompression issues

Signed-off-by: Felix Fietkau <nbd@nbd.name>
3 years agobase-files: bump Copyright to 2021
Paul Spooren [Wed, 27 Jan 2021 03:21:48 +0000 (17:21 -1000)]
base-files: bump Copyright to 2021

This commit is only added to keep the PKG_RELEASE correct after fixing
the $(COMMITCOUNT) logic in the previous commit.

This way the PKG_RELEASE stays the same while the compiled packages
content isn't changed.

Signed-off-by: Paul Spooren <mail@aparcar.org>
3 years agorules: fix COMMITCOUNT logic
Paul Spooren [Wed, 27 Jan 2021 03:16:36 +0000 (17:16 -1000)]
rules: fix COMMITCOUNT logic

The newly added $(COMMITCOUNT) variable was wrongly increased by plus
one. The addition should have been only added to $(AUTORELEASE) as
OpenWrt traditionally starts counting at one rather than zero.

$(AUTORELEASE) counts the commits since the last bump, which is zero on
the version bump commit itself.

This commit increases $(AUTORELEASE) by one while leaving $(COMMITCOUNT)
as is.

The base-files package is the only package using $(COMMITCOUNT) so far
and requires a pseudo commit to keep the PKG_RELEASE correct. A non
functional change (Copyright bump) is done in the next commit.

Signed-off-by: Paul Spooren <mail@aparcar.org>
3 years agopx5g-wolfssl: Fix certificate signature
Jeffrey Elms [Wed, 27 Jan 2021 02:28:14 +0000 (18:28 -0800)]
px5g-wolfssl: Fix certificate signature

Certificate signature algorithm was being set after call to
`wc_MakeCert`, resulting in a mismatch between specified signature in
certificate and the actual signature type.

Signed-off-by: Jeffrey Elms <jeff@wolfssl.com>
[fix commit subject, use COMMITCOUNT]
Signed-off-by: Paul Spooren <mail@aparcar.org>
3 years agotoolchain/libstdcpp: disable dual ABI and default to new
Rosen Penev [Thu, 21 Jan 2021 04:51:45 +0000 (20:51 -0800)]
toolchain/libstdcpp: disable dual ABI and default to new

GCC 5.1 changed the std::string ABI in order to properly support C++11.
For compatibility with libraries compiled with the older ABI, that is,
linking between old-abi.so and new-abi.bin, both ABIs are enabled. In
terms of OpenWrt, all packages are compiled with the same toolchain,
which means these issues do not need to be handled.

Most importantly, this results in a significant size reduction of
libstdpp:

Before:

450794 bytes

After:

327752 bytes

Tested with all OpenWrt packages.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
3 years agoumdns: bump to 2021-01-26
Paul Spooren [Tue, 26 Jan 2021 19:49:14 +0000 (09:49 -1000)]
umdns: bump to 2021-01-26

* i78aa36b umdns: fix 64-bit time format string
* start using $(AUTORELEASE)
* Update Copyright

Signed-off-by: Paul Spooren <mail@aparcar.org>
3 years agomac80211: fix an uninitialized variable warning
Felix Fietkau [Tue, 26 Jan 2021 18:25:10 +0000 (19:25 +0100)]
mac80211: fix an uninitialized variable warning

Signed-off-by: Felix Fietkau <nbd@nbd.name>
3 years agomac80211: minstrel_ht: fix regression in the max_prob_rate fix
Felix Fietkau [Tue, 26 Jan 2021 15:46:19 +0000 (16:46 +0100)]
mac80211: minstrel_ht: fix regression in the max_prob_rate fix

Signed-off-by: Felix Fietkau <nbd@nbd.name>
3 years agomac80211: remove accidentally duplicated line in minstrel_ht patch
Felix Fietkau [Mon, 25 Jan 2021 17:22:30 +0000 (18:22 +0100)]
mac80211: remove accidentally duplicated line in minstrel_ht patch

Signed-off-by: Felix Fietkau <nbd@nbd.name>
3 years agorealtek: add debugfs support for mirroring
Birger Koblitz [Thu, 21 Jan 2021 14:18:24 +0000 (15:18 +0100)]
realtek: add debugfs support for mirroring

This adds debugfs support to monitor mirroring via debugfs

Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
3 years agorealtek: add API for the hw tables of RTL83XX/93XX SoCs
Birger Koblitz [Thu, 21 Jan 2021 14:16:24 +0000 (15:16 +0100)]
realtek: add API for the hw tables of RTL83XX/93XX SoCs

Add a table API that has per accss register locking and uses
register description information to handle all table access
through a single set of api calls.

Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
3 years agorealtek: add switch driver support for the RTL93XX based switches
Birger Koblitz [Thu, 21 Jan 2021 14:14:56 +0000 (15:14 +0100)]
realtek: add switch driver support for the RTL93XX based switches

Adds support for the RTL9300 and RTL9310 series of switches
with 10GBit per port and up to 56 ports.

Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
3 years agorealtek: add internal and external SDS/PHYs of RTL9300 devices
Birger Koblitz [Thu, 21 Jan 2021 14:12:36 +0000 (15:12 +0100)]
realtek: add internal and external SDS/PHYs of RTL9300 devices

This adds support for the internal SerDes of the RTL9300 SoC
and for the RTL8218D and RTL8226B phys found in combination
with this SoC in switches.

Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
3 years agorealtek: fix RTL8231 gpio expander usage with RTL839X SoC
Birger Koblitz [Thu, 21 Jan 2021 14:09:47 +0000 (15:09 +0100)]
realtek: fix RTL8231 gpio expander usage with RTL839X SoC

This fixes the usage of the RTL8231 GPIO extender chip
when used with the RTL839X SoCs. Specifically,
the PHY addresses may be different from 0.

Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
3 years agorealtek: enable default rate limiting and qos settings
Birger Koblitz [Thu, 21 Jan 2021 13:35:26 +0000 (14:35 +0100)]
realtek: enable default rate limiting and qos settings

Enable default rate limiting and QoS support. Remove
previous storm control code.

Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
3 years agorealtek: correct l2 offloading tag handling
Birger Koblitz [Thu, 21 Jan 2021 13:32:44 +0000 (14:32 +0100)]
realtek: correct l2 offloading tag handling

Makes sure the DSA trailer information on any L2 offloading done
by the switch is honoured by the bridge layer

Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
3 years agorealtek: add QoS and rate control
Birger Koblitz [Thu, 21 Jan 2021 13:29:52 +0000 (14:29 +0100)]
realtek: add QoS and rate control

This adds support for identifying QoS information in packets
and use this and rate control information to submit to multiple
egress queues. The ethernet driver is also made to support
2 egress and up to 32 egress queues.

Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
3 years agorealtek: add dtsi for RTL930X SoCs
Birger Koblitz [Thu, 21 Jan 2021 20:41:37 +0000 (21:41 +0100)]
realtek: add dtsi for RTL930X SoCs

Add a default dtsi to support RTL930X SoCs.

Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
3 years agorealtek: add support for the RTL9300 timer
Birger Koblitz [Thu, 21 Jan 2021 20:38:27 +0000 (21:38 +0100)]
realtek: add support for the RTL9300 timer

this adds support for the SoC timer of the RTL9300 chips, it
provides 6 independent timer/counters, of which the first one
is used as a clocksource and the second one as event timer.

Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
3 years agorealtek: add support for the RTL8390 and RTL9300 SoC IRQs
Birger Koblitz [Thu, 21 Jan 2021 13:11:35 +0000 (14:11 +0100)]
realtek: add support for the RTL8390 and RTL9300 SoC IRQs

This adds support for the RTL8390 and RTL9300 SoCs
it also cleans up unnecessary definitions in mach-rtl83xx.h
and moves definitions relevant for irq routing to irq.h

Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
3 years agorealtek: add detection of RTL930X SoCs and RTL8313 SoC
Birger Koblitz [Thu, 21 Jan 2021 13:07:38 +0000 (14:07 +0100)]
realtek: add detection of RTL930X SoCs and RTL8313 SoC

This adds support to detect RTL930X based SoCs and the RTL9313 SoC.
Tested on Zyxel XGS1210-10 (RTL9302B SoC) and the
Zyxel XS1930-12 (RTL9313 SoC)

Signed-off-by: Birger Koblitz <git@birger-koblitz.de>
3 years agokernel: bump 5.4 to 5.4.92
John Audia [Sat, 23 Jan 2021 16:09:03 +0000 (11:09 -0500)]
kernel: bump 5.4 to 5.4.92

All modification made by update_kernel.sh in a fresh clone without
existing toolchains.

Build system:       x86_64
Build-tested:       ipq806x/R7800, bcm27xx/bcm2711
Run-tested:         ipq806x/R7800
Compile-tested [*]: ath79/{tiny,generic}, ipq40xx, octeon,
                    ramips/mt7621, realtek, x86/64.
Run-tested [*]:     ath79/generic, octeon, ramips/mt7621, realtek.

No dmesg regressions, everything functional

Signed-off-by: John Audia <graysky@archlinux.us>
Tested-by: Stijn Segers <foss@volatilesystems.org> [*]
3 years agobpftools: update to 5.10.10
Tony Ambardar [Tue, 15 Dec 2020 05:39:19 +0000 (21:39 -0800)]
bpftools: update to 5.10.10

Use the latest stable kernel since the previous 5.8.x series is EOL.

Also drop the following patches recently accepted upstream:

  * 001-libbpf-ensure-no-local-symbols-counted-in-ABI-check.patch
  * 002-libbpf-fix-build-failure-from-uninitialized-variable.patch
  * 003-bpftool-allow-passing-BPFTOOL_VERSION-to-make.patch
  * 004-v5.9-bpftool-use-only-ftw-for-file-tree-parsing.patch

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
3 years agoconfig: limit CONFIG_PERF_EVENTS to top-level generic configs
Tony Ambardar [Wed, 21 Oct 2020 16:13:45 +0000 (09:13 -0700)]
config: limit CONFIG_PERF_EVENTS to top-level generic configs

Remove redundant target-level settings.

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
3 years agoconfig: drop CONFIG_KPROBE_EVENT unused since kernel 4.9
Tony Ambardar [Wed, 21 Oct 2020 16:24:33 +0000 (09:24 -0700)]
config: drop CONFIG_KPROBE_EVENT unused since kernel 4.9

The config setting was renamed to CONFIG_KPROBE_EVENTS.

Fixes: 97d3f800a8 ("config: kernel: Add KPROBE_EVENTS config option)
Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
3 years agomalta: update target configs and fix build warnings
Tony Ambardar [Mon, 27 Jul 2020 11:36:21 +0000 (04:36 -0700)]
malta: update target configs and fix build warnings

Comment out some conflicting target configs that are set from subtarget
configs, which sometimes lead to kernel compile warnings:

  scripts/kconfig/conf  --syncconfig Kconfig
  net/sched/Kconfig:45: warning: menuconfig statement without prompt
  .config:1038:warning: override: CPU_MIPS32_R2 changes choice state

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
3 years agomac80211: add significant minstrel_ht performance improvements
Felix Fietkau [Fri, 22 Jan 2021 23:17:31 +0000 (00:17 +0100)]
mac80211: add significant minstrel_ht performance improvements

Completely redesign the rate sampling approach

Signed-off-by: Felix Fietkau <nbd@nbd.name>
3 years agorealtek: build ZyXEL vendor firmware compatible initramfs
Bjørn Mork [Sat, 23 Jan 2021 10:08:12 +0000 (11:08 +0100)]
realtek: build ZyXEL vendor firmware compatible initramfs

Append a device specific version trailer used by the stock
firmware upgrade application to validate firmwares.

The trailer contains a list of ZyXEL firmware version
numbers, which includes a four letter hardware identifier.
The stock web UI requires that the current hardware matches
one of the listed versions, and that the version number is
larger than a model specific minimum value. The minimum
version varies between V1.00 and V2.60 for the currently
known GS1900 models. The number is not used anywhere else
to our knowlege, and has no direct relation to the version
info in the u-image header.  We can therefore use an
arbitrary value larger than V2.60.

The stock firmware upgrade application will only load and
flash the part of the file specified in the u-image header,
regardless of file size.  It can therefore not be used to
flash images with an appended rootfs. There is therefore no
need to include the trailer in other images than the
initramfs. This prevents accidentally bricking by attempts
to flash other images from the stock web UI.

Stock images support all models in the series, listing
all of them in the version trailer.  OpenWrt provide model
specific images.  We therefore only list the single supported
hardware identifier for each image.  This eliminates the risk
of flashing the wrong OpenWrt image from stock web UI.

OpenWrt can be installed from stock firmware in two steps:

   1) flash OpenWrt initramfs image from stock web gui
   2) boot OpenWrt and sysupgrade to a squasfs image

The OpenWrt squashfs image depends on a static partition
map in the DTS.  It can only be installed to the "firmware"
partition.  This partition is labeled "RUNTIME1" in u-boot
and in stock firmware, and is referred to as "image 0" in
the stock flash management tool.  The OpenWrt initramfs
can be installed and run from either partitions. But if
you want to keep stock irmware in the spare system partition,
then you must make sure stock firmware is installed to the
"RUNTIME2" partition referred to as "image 1" in the stock
web UI. And the initial OpenWrt initramfs must be flashed
to "RUNTIME1"/"image 0".

The stock flash management application supports direct
selection of both which partition to flash and which
partition to boot next.  This allows software controlled
"dual-boot" between OpenWrt and stock firmware, without
using console access to u-boot. u-boot use the "bootpartition"
variable stored in the second u-boot environment to select
which of the two system partitions to boot.  This variable
is set by the stock flash management application, by direct
user input.  It can also be set in OpenWrt using e.g

 fw_setsys bootpartition 1

to select "RUNTIME2"/"image 1" as default, assuming a
stock firmware version is installed in that partition.

Signed-off-by: Bjørn Mork <bjorn@mork.no>
3 years agorealtek: use vendor-specific magic for ZyXEL
Bjørn Mork [Sat, 23 Jan 2021 10:08:11 +0000 (11:08 +0100)]
realtek: use vendor-specific magic for ZyXEL

The stock firmware of the ZyXEL GS1900 series use a non-standard
u-image magic.  This is not enforced by the stock u-boot, which is
why we could boot images with the default magic.  The flash
management application of the stock firmware will however verify
the magic, and refuse any image with another value.

Convert to vendor-specific value to get flash management support
in stock firmware, including the ability to upgrade to OpenWrt
directly from stock web UI.

Signed-off-by: Bjørn Mork <bjorn@mork.no>