openwrt/staging/hauke.git
18 months agof2fs-tools: update to 1.16.0
Nick Hainke [Sun, 7 May 2023 15:58:26 +0000 (17:58 +0200)]
f2fs-tools: update to 1.16.0

Remove upstramed patches:
- 100-configure.ac-fix-AC_ARG_WITH.patch
- 101-configure.ac-fix-cross-compilation.patch

Remove deprecated f2fstat tool:
https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git/commit/?id=77bf7ed29f1dd1341079913f3b36fc62f812c4f5

Changelog:
06c027a f2fs-tools: upgrade version 1.16.0
542cc57 fsck.f2fs: fix sanity check logic for cp_payload
a7df89e mkfs.f2fs: remove indentation
c82985a fsck.f2fs: don't call report_zone on normal partition
0ac168e f2fs-tools: relax zone size of power of 2
641be32 mkfs.f2fs: trim all the devices except the first one
3835fef f2fs-tools: fix # of total segments
5b08ca9 f2fs_io: support AES_256_HCTR2
ae3301c f2fs_io: Fix out of tree builds
ddbde27 fsck.f2fs: relocate chksum verification step during f2fs_do_mount()
77bf7ed f2fs-tools: Remove deprecated f2fstat
fb6575e Remove sg_write_buffer
1bb669e fsck.f2fs: avoid uncessary recalculation
ccd2361 fsck.f2fs: fix potential overflow of copying i_name
cd6b133 fsck.f2fs: add parentheses for SB_MASK
399600a dump.f2fs: remove unavailable option -g
3e6e178 f2fs-tools: define HAVE_CLOCK_GETTIME properly
907b972 f2fs-tools: support F2FS_IOC_START_ATOMIC_REPLACE
9ff70fb f2fs-tools: give less overprovisioning space
844f821 f2fs-tools: set host-aware zoned device similar to host-managed one
88ac76d fsck.f2fs: fix missing to assign c.zoned_model
8cbe34e fsck.f2fs: trigger repairing if filesystem has inconsistent errors
2f1dde2 fsck.f2fs: trigger repairing if filesystem was forced to stop
465159f fsck.f2fs: export valid image size
3486b62 mkfs.f2fs: update allocation policy for ro feature
bdd51e5 fsck.f2fs: fix __end_block_addr()
5a5e419 Always use sparse/sparse.h when building for Android
19f77c6 f2fs-tools: fix build error on lz4-1.9.4
986c1f1 Fix format strings in log messages
0d6acbe fsck.f2fs: use elapsed_time in checkpoint for period check
9b7a4c5 mkfs.f2fs: catch total_zones=0 instead of crashing
6148db3 f2fs-tools: use F2FS_BLKSIZE instead of PAGE_*_SIZE
f09c2b7 f2fs_io: support triggering filesystem GC via ioctl
32e7d27 configure.ac: fix cross compilation
65fe94e configure.ac: fix AC_ARG_WITH
6325cf7 Use F2FS_BLKSIZE as the size of struct f2fs_summary_block
c89be7a Use F2FS_BLKSIZE for dev_read_block() buffers
5317d18 Improve compile-time type checking for f2fs_report_zone()
92e2e52 Fix f2fs_report_zone()
648a491 Fix the struct f2fs_dentry_block definition
c964547 resize.f2fs: add option to manually specify new overprovision
a741438 fsck.f2fs: drop compression bit if inline_data is set
406b1c9 f2fs-tools: fix cannot get bdev information
9d0cb9e f2fs_io: add dsync option for write
a7b8b46 tools: fix file too large causing overflow
bddca6f dump.f2fs: add -I nid to dump inode by scan full disk
ebc3879 android_config: add time headers
c1144bf Check fallthrough in mount.h for Mac
bcb9929 avoid unnecessary function
7d902f4 Fix dependencies on linux/blkzoned.h when using Bionic.
274abbb Remove unnecessary config.h
8c97ab3 libzone: remove duplicate header
adcec10 Support zoned device if libc exists
efc2bc7 mkfs.f2fs: fix typo
3034a41 mkfs.f2fs: split unused parameter
dd8d8e5 f2fs-tools: do not use SG_IO in Android
4f216e6 f2fs-tools: move android_config before defining them
48c5dbb f2fscrypt: adjust config file first
4b55459 android_config: add missing uuid library

Signed-off-by: Nick Hainke <vincent@systemli.org>
18 months agoath25: Replace fall through comment with fallthrough;
Hauke Mehrtens [Thu, 18 May 2023 14:19:47 +0000 (16:19 +0200)]
ath25: Replace fall through comment with fallthrough;

Replace the fall through comment with fallthrough; in the ar2315 flash
driver.
This fixes a compile warning.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
18 months agoath25: Remove virt_to_phys() from Ethernet driver
Hauke Mehrtens [Thu, 18 May 2023 14:17:58 +0000 (16:17 +0200)]
ath25: Remove virt_to_phys() from Ethernet driver

Instead of defining an own virt_to_phys() use the version from the
generic MIPS arch code which does the same.
This fixes a compile warning.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
18 months agoutil-linux: Fix build on powerpc and arc
Hauke Mehrtens [Thu, 18 May 2023 17:29:18 +0000 (19:29 +0200)]
util-linux: Fix build on powerpc and arc

This fixes the build of util-linux on powerpc and arc. Both CPU
architectures were not supported here in addition to the missing MIPS
support.

Fixes: 628a410ed149 ("util-linux: update to 2.39")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
18 months agomediatek: fix append-gl-metadata when running in buildbot
Daniel Golle [Fri, 19 May 2023 08:31:36 +0000 (09:31 +0100)]
mediatek: fix append-gl-metadata when running in buildbot

Use same logic as in append-metadata so build doesn't fail in case of
missing build-key (it was previously failing on the buildbot runners).

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
18 months agoipq40xx: fix rebooting after 5.15.111
Robert Marko [Thu, 18 May 2023 10:20:15 +0000 (12:20 +0200)]
ipq40xx: fix rebooting after 5.15.111

Kernel 5.15.111 includes backport of commit
("firmware: qcom_scm: Clear download bit during reboot") which is causing
reboot on ipq40xx to stop working, more precisely the board will hang after
reboot is called with:
root@OpenWrt:/# reboot
root@OpenWrt:/# [   76.473541] device lan1 left promiscuous mode
[   76.474204] br-lan: port 1(lan1) entered disabled state
[   76.527975] device lan2 left promiscuous mode
[   76.530301] br-lan: port 2(lan2) entered disabled state
[   76.579376] device lan3 left promiscuous mode
[   76.581698] br-lan: port 3(lan3) entered disabled state
[   76.638434] device lan4 left promiscuous mode
[   76.638777] br-lan: port 4(lan4) entered disabled state
[   76.978489] qca8k-ipq4019 c000000.switch wan: Link is Down
[   76.978883] device eth0 left promiscuous mode
[   76.987077] ipqess-edma c080000.ethernet eth0: Link is Down
[
Format: Log Type - Time(microsec) - Message - Optional Info
Log Type: B - Since Boot(Power On Reset),  D - Delta,  S - Statistic
S - QC_IMAGE_VERSION_STRING=BOOT.BF.3.1.1-00123
S - IMAGE_VARIANT_STRING=DAABANAZA
S - OEM_IMAGE_VERSION_STRING=CRM
S - Boot Config, 0x00000021
S - Reset status Config, 0x00000010
S - Core 0 Frequency, 0 MHz
B -       261 - PBL, Start
B -      1339 - bootable_media_detect_entry, Start
B -      1679 - bootable_media_detect_success, Start
B -      1693 - elf_loader_entry, Start
B -      5076 - auth_hash_seg_entry, Start
B -      7223 - auth_hash_seg_exit, Start
B -    578349 - elf_segs_hash_verify_entry, Start
B -    696356 - PBL, End
B -    696380 - SBL1, Start
B -    787236 - pm_device_init, Start
D -         7 - pm_device_init, Delta
B -    788701 - boot_flash_init, Start
D -     52782 - boot_flash_init, Delta
B -    845625 - boot_config_data_table_init, Start
D -      3836 - boot_config_data_table_init, Delta - (419 Bytes)
B -    852841 - clock_init, Start
D -      7566 - clock_init, Delta
B -    864883 - CDT version:2,Platform ID:9,Major ID:0,Minor ID:0,Subtype:64
B -    868413 - sbl1_ddr_set_params, Start
B -    873402 - cpr_init, Start
D -         2 - cpr_init, Delta
B -    877842 - Pre_DDR_clock_init, Start
D -         4 - Pre_DDR_clock_init, Delta
D -     13234 - sbl1_ddr_set_params, Delta
B -    891155 - pm_driver_init, Start
D -         2 - pm_driver_init, Delta
B -    909105 - Image Load, Start
B -   1030210 - Boot error ocuured!. Error code: 303d

So, until a proper fix is found, lets revert the culprit patch to have
reboot working again.

Fixes: 228e0e10398b ("kernel: bump 5.15 to 5.15.111")
Signed-off-by: Robert Marko <robimarko@gmail.com>
18 months agotoolchain: glibc: Fix build with autoconf 2.71
Hauke Mehrtens [Wed, 17 May 2023 22:31:21 +0000 (00:31 +0200)]
toolchain: glibc: Fix build with autoconf 2.71

The glibc build was failing with this error message:
  aclocal.m4:6: error: Exactly version 2.69 of Autoconf is required but you have 2.71
  aclocal.m4:6: the top level

The autoconf run on glibc is not needed, just remove it.

Fixes: #12631
Fixes: 030447b8f4c7 ("tools/autoconf: bump to 2.71")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
18 months agotoolchain: glibc: Update glibc 2.37 to recent HEAD
Hauke Mehrtens [Wed, 17 May 2023 22:27:22 +0000 (00:27 +0200)]
toolchain: glibc: Update glibc 2.37 to recent HEAD

This adds the following changes:
790e504a17 stdlib: Undo post review change to 16adc58e73f3 [BZ #27749]
590d0e089b elf: Restore ldconfig libc6 implicit soname logic [BZ #30125]
1d63573f81 stdio-common: tests: don't double-define _FORTIFY_SOURCE
97ad4c64b9 gshadow: Matching sgetsgent, sgetsgent_r ERANGE handling (bug 30151)
9cc2f41e52 x86_64: Fix asm constraints in feraiseexcept (bug 30305)
78ab913eab posix: Fix system blocks SIGCHLD erroneously [BZ #30163]
5d750495db gmon: Fix allocated buffer overflow (bug 29444)
d230623264 gmon: improve mcount overflow handling [BZ# 27576]
ff3a71ec1f gmon: fix memory corruption issues [BZ# 30101]
a908c18d47 gmon: Revert addition of tunables to preserve GLIBC_PRIVATE ABI
7c32cb7dd8 gmon: Revert addition of tunables to the manual

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
18 months agokernel: bump 5.15 to 5.15.112
John Audia [Thu, 18 May 2023 10:18:23 +0000 (06:18 -0400)]
kernel: bump 5.15 to 5.15.112

Manually adjusted before running quilt due to new location in tree:
backport-5.15/780-v5.16-bus-mhi-pci_generic-Introduce-Sierra-EM919X-support.patch
backport-5.15/781-v6.1-bus-mhi-host-always-print-detected-modem-name.patch
pending-5.15/790-bus-mhi-core-add-SBL-state-callback.patch

All other patches automatically rebased.

Build system: x86_64
Build-tested: bcm2711/RPi4B, ramips/tplink_archer-a6-v3, filogic/xiaomi_redmi-router-ax6000-ubootmod
Run-tested: bcm2711/RPi4B, ramips/tplink_archer-a6-v3, filogic/xiaomi_redmi-router-ax6000-ubootmod

Signed-off-by: John Audia <therealgraysky@proton.me>
18 months agokernel: other: adjust paths for new location
John Audia [Thu, 18 May 2023 10:16:11 +0000 (06:16 -0400)]
kernel: other: adjust paths for new location

This upstream commit[1] moves drivers/bus/mhi/core/ to
drivers/bus/mhi/host/ so we need to correct for that here.

https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.112&id=9fbf10148f31a63b6d8c2b0e56cb97eb173d600b

Signed-off-by: John Audia <therealgraysky@proton.me>
18 months agoumdns: Update to umdns HEAD
Mark Baker [Thu, 11 May 2023 19:15:57 +0000 (15:15 -0400)]
umdns: Update to umdns HEAD

Update to umdns HEAD to include latest enhancements for browse method
filtering, return of TXT records as an array, dumping IPv4/6 as an
array, and including the interface name in a browse reply.

Signed-off-by: Mark Baker <mark@vpost.net>
Tested-by: Stefan Lippers-Hollmann <s.l-h@gmx.de> #ipq807x, mt7621, x86_64
18 months agorockchip: add NanoPi R2C support
Tianling Shen [Sat, 13 May 2023 05:54:38 +0000 (13:54 +0800)]
rockchip: add NanoPi R2C support

The NanoPi R2C is a minor variant of NanoPi R2S with the on-board NIC
chip changed from rtl8211e to yt8521s, and otherwise identical to R2S.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
18 months agouboot-rockchip: add NanoPi R2C support
Tianling Shen [Sat, 13 May 2023 05:54:38 +0000 (13:54 +0800)]
uboot-rockchip: add NanoPi R2C support

Add support for the FriendlyARM NanoPi R2C.
Manually generated of-platdata files to avoid swig dependency.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
18 months agokernel: backport Motorcomm YT8521/YT8531 support
Tianling Shen [Sat, 13 May 2023 05:54:38 +0000 (13:54 +0800)]
kernel: backport Motorcomm YT8521/YT8531 support

It will be used on NanoPi R2C and OrangePi R1 Plus LTS board.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
18 months agorockchip: move UBOOT_DEVICE_NAME to default
Tianling Shen [Sat, 13 May 2023 04:34:45 +0000 (12:34 +0800)]
rockchip: move UBOOT_DEVICE_NAME to default

Simplify variable usage.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
18 months agorockchip: merge bootscript
Tianling Shen [Sat, 13 May 2023 04:19:52 +0000 (12:19 +0800)]
rockchip: merge bootscript

The bootscript for nanopi r2s/r4s only changes the serial address, so
make it auto detected in mmc bootscript rather than creating more
(redudant) files.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
18 months agouboot-rockchip: cleanup redudant variables
Tianling Shen [Sat, 13 May 2023 04:16:21 +0000 (12:16 +0800)]
uboot-rockchip: cleanup redudant variables

Instead of adding these common variables again and again simply create a
shared set for each SoC.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
18 months agogpio-button-hotplug: do not error on interrupt attached keys
Tim Harvey [Tue, 28 Feb 2023 00:56:25 +0000 (16:56 -0800)]
gpio-button-hotplug: do not error on interrupt attached keys

The Linux gpio-keys driver bindings allow for GPIO attached or interrupt
attached keys. Currently if an interrupt attached key is encountered
gpio_keys_button_probe() will fail due to not being able to get a gpio
descriptor:
gpio-keys: probe of gpio-keys failed with error -2

Skip the failure in the case of interrupt attached keys to resolve this.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
18 months agoipq806x: remove dangling ipq-wifi-edgecore_ecw5410
Christian Lamparter [Thu, 18 May 2023 15:08:54 +0000 (17:08 +0200)]
ipq806x: remove dangling ipq-wifi-edgecore_ecw5410

should have been part of the ipq-wifi update.

Fixes: 8217f02a1c5e ("ipq-wifi: drop upstreamed board-2.bin")
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
18 months agoimx: image: ventana: add blkdev compressed disk image
Tim Harvey [Fri, 17 Feb 2023 22:03:46 +0000 (14:03 -0800)]
imx: image: ventana: add blkdev compressed disk image

Add a ventana-img.gz compressed disk image to support
squashfs+ext4 on a block storage device such as USB/MMC/SATA.

The Ventana bootloader expects the bootscript to be
boot/6x_bootscript-ventana therefore we must create a bootfs
that matches this.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
18 months agoimx: image: ventana: use squashfs rootfs for non NAND devices
Tim Harvey [Fri, 17 Feb 2023 22:03:45 +0000 (14:03 -0800)]
imx: image: ventana: use squashfs rootfs for non NAND devices

In order to support squashfs+ext4 define rootfstype=squashfs and use P2
as P1 is boot filesystem.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
18 months agoutil-linux: update to 2.39
Thomas Weißschuh [Wed, 17 May 2023 14:58:19 +0000 (16:58 +0200)]
util-linux: update to 2.39

Release Notes:
https://cdn.kernel.org/pub/linux/utils/util-linux/v2.39/v2.39-ReleaseNotes

Remove upstreamed:
030-meson-don-t-use-run.patch
040-meson-fix-cpu_set_t-test.patch
050-meson-fix-environ-search.patch
060-meson-add-_GNU_SOURCE-for-sighandler_t.patch
070-meson-fix-isnan-check.patch
080-meson-fix-tzname-check.patch
090-meson-libpam.patch
100-meson-make-libcap-ng-dependent-on-setpriv.patch
120-meson-get-the-project-version-from-the-version-gen-s.patch
130-meson-fix-error-in-processing-version-for-pc-files.patch

New:
0001-test_enosys-add-support-for-mips.patch

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
[Refresh patches]
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
18 months agoksmbd: remove
Rosen Penev [Fri, 12 May 2023 15:43:31 +0000 (08:43 -0700)]
ksmbd: remove

In tree ksmbd is available with 5.15 and is better updated.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
18 months agolinux/modules: add ksmbd support for 5.15
Rosen Penev [Thu, 19 May 2022 03:11:38 +0000 (20:11 -0700)]
linux/modules: add ksmbd support for 5.15

5.15 is the first version to come with ksmbd. Use it instead of the
module as the linux one is better maintained.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
18 months agokernel: modules: split smbfs-common from cifs
John Thomson [Sat, 24 Dec 2022 12:57:34 +0000 (22:57 +1000)]
kernel: modules: split smbfs-common from cifs

This kernel config symbol is a shared library used for both CIFS and the
in-tree SMB_SERVER.
Split it out into kmod-fs-smbfs-common from kmod-fs-cifs, and depend on
it, so that later in-tree ksmbd may also depend on it.

Signed-off-by: John Thomson <git@johnthomson.fastmail.com.au>
18 months agoramips: add basic common recipe for nand flash devices
Shiji Yang [Sat, 13 May 2023 13:01:00 +0000 (21:01 +0800)]
ramips: add basic common recipe for nand flash devices

These same codes are repeated for many devices now, it's better to
move them to shared definition. This commit also add the missing
KERNEL_SIZE of the ZyXEL NR7101 and ZyXEL LTE3301-PLUS.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
18 months agoramips: set default BLOCKSIZE to 64k for nor flash devices
Shiji Yang [Sat, 13 May 2023 13:01:00 +0000 (21:01 +0800)]
ramips: set default BLOCKSIZE to 64k for nor flash devices

In kernel 5.15, the default erase sector size of the nor flash has
been switched from 4k to 64k. This may cause the configuration not
be preserved across upgrades. To avoid this issue, change the default
BLOCKSIZE to 64k.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
18 months agoramips: enable variable sector size erasure for all subtarget
Shiji Yang [Sat, 13 May 2023 13:00:59 +0000 (21:00 +0800)]
ramips: enable variable sector size erasure for all subtarget

Make use of minor sector size (4k) on supported flash chips to improve
spi read/write performance.

Tested on ramips/mt7628: Motorola MWR03

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
18 months agokernel: add MODULE_ALLOW_BTF_MISMATCH option
Tianling Shen [Tue, 16 May 2023 04:38:53 +0000 (12:38 +0800)]
kernel: add MODULE_ALLOW_BTF_MISMATCH option

BTF mismatch can occur for a separately-built module even when the ABI
is otherwise compatible and nothing else would prevent successfully
loading. Add a new config to control how mismatches are handled. By
default, preserve the current behavior of refusing to load the
module. If MODULE_ALLOW_BTF_MISMATCH is enabled, load the module but
ignore its BTF information.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
18 months agoipq-wifi: drop upstreamed board-2.bin
Christian Lamparter [Wed, 17 May 2023 20:02:40 +0000 (22:02 +0200)]
ipq-wifi: drop upstreamed board-2.bin

The BDFs for the:
Aruba AP-365
Devolo Magic 2 WiFi next
Edgecore ECW5410
Edgecore OAP100
Extreme Networks WS-AP3915i
GL.iNet GL-A1300
GL.iNet GL-AP1300
GL.iNet GL-S1300
Linksys EA8300
Linksys WHW03v2
Nokia Wi4A AC400i
P&W R619AC
Pakedge WR-1
Qxwlan E2600AC C1
Sony NCP-HG100/Cellular
Teltonika RUTX10
ZTE MF18A

were upstreamed to the ath10k-firmware repository
and landed in linux-firmware.git.

Furthermore the BDFs for the:
8devices Habanero
8devices Jalapeno
Qxwlan E2600AC C2

have been updated.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
18 months agomvebu: use PHY LED trigger for speed LEDs on FortiGate 50E
INAGAKI Hiroshi [Thu, 23 Mar 2023 14:06:14 +0000 (23:06 +0900)]
mvebu: use PHY LED trigger for speed LEDs on FortiGate 50E

Use <mdio>:<addr>:<speed> trigger instead of netdev(link) trigger for
Fortinet FortiGate 50E, to indicate link speed on the each phys.

1000 Mbps: Green
100 Mbps : Amber
10 Mbps  : (turn off)

Fixes: 102dc5a62506 ("mvebu: add support for Fortinet FortiGate 50E")
Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
18 months agomvebu: cortexa9: enable Ethernet PHY LED trigger
INAGAKI Hiroshi [Thu, 23 Mar 2023 14:06:13 +0000 (23:06 +0900)]
mvebu: cortexa9: enable Ethernet PHY LED trigger

To use <mdio>:<addr>:<speed> trigger for LEDs, enable PHY LED trigger
(CONFIG_LED_TRIGGER_PHY).

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
18 months agodownload: create immutable subversion checkout archive
Tomasz Maciej Nowak [Wed, 10 May 2023 17:07:07 +0000 (19:07 +0200)]
download: create immutable subversion checkout archive

On each generation of the archive check sum will differ, because when
checking out subversion repository, current date is used for directories
creation. Force tar to assign creation date of the last revision for all
items inside archive.

Signed-off-by: Tomasz Maciej Nowak <tmn505@gmail.com>
18 months agoscripts/gen_image_generic.sh: allow passing in partition offset
Tim Harvey [Wed, 22 Mar 2023 16:02:52 +0000 (09:02 -0700)]
scripts/gen_image_generic.sh: allow passing in partition offset

Allow passing in an optional offset (PARTOFFSET) for the first partition.
If not specified this will default to 256K (512 blocks) as it has before.

For example if you want to start partition data at a 16M offset instead
of 256K, specify 'PARTOFFSET=16M'.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
18 months agoocteontx: kernel: add USB storage boot support
Tim Harvey [Thu, 23 Feb 2023 23:23:42 +0000 (15:23 -0800)]
octeontx: kernel: add USB storage boot support

Enable BLK_DEV_SD and USB_STORAGE so that rootfs can be on a USB Mass
Storage device.

This increases the kernel Image by 66KiB

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
18 months agoimx: kernel: add USB storage boot support
Tim Harvey [Thu, 23 Feb 2023 23:24:18 +0000 (15:24 -0800)]
imx: kernel: add USB storage boot support

Enable BLK_DEV_SD and USB_STORAGE so that rootfs can be on a USB Mass
Storage device.

This adds 23KiB to the compressed kernel size

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
18 months agonu801: add kmod-leds-uleds to MR26 + MR18
Christian Lamparter [Wed, 17 May 2023 20:33:36 +0000 (22:33 +0200)]
nu801: add kmod-leds-uleds to MR26 + MR18

support for MR18 and MR26 was developped before
the userspace nu801 was integrated with x86's
MX100 into OpenWrt. The initial nu801 + kmod-leds-uleds
caused build-bot errors.

The solution that worked for the MX100 was to include
the kmod-leds-uleds to the device platform module.
Thankfully, the MR26 and MR18 can just add the uleds
package to the DEVICE_PACKAGES variable.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
18 months agolibxml2: update to 2.11.3
Nick Hainke [Thu, 18 May 2023 10:06:00 +0000 (12:06 +0200)]
libxml2: update to 2.11.3

Changelog:
- https://gitlab.gnome.org/GNOME/libxml2/-/releases/v2.10.4
- https://gitlab.gnome.org/GNOME/libxml2/-/releases/v2.11.0
- https://gitlab.gnome.org/GNOME/libxml2/-/releases/v2.11.1
- https://gitlab.gnome.org/GNOME/libxml2/-/releases/v2.11.2
- https://gitlab.gnome.org/GNOME/libxml2/-/releases/v2.11.3

Fixes: CVE-2023-28484 CVE-2023-29469
Signed-off-by: Nick Hainke <vincent@systemli.org>
18 months agoramips: rename to D-Team Newifi D2 and Lenovo Newifi D1
Arınç ÜNAL [Tue, 18 Apr 2023 13:42:41 +0000 (16:42 +0300)]
ramips: rename to D-Team Newifi D2 and Lenovo Newifi D1

Rename Newifi D2 to D-Team Newifi D2, and Newifi D1 to Lenovo Newifi D1.
Let's not make naming exceptions because of marketing whims.

Signed-off-by: Arınç ÜNAL <arinc.unal@arinc9.com>
18 months agoramips: add support for TOZED ZLT S12 PRO
Arınç ÜNAL [Wed, 29 Mar 2023 10:11:30 +0000 (13:11 +0300)]
ramips: add support for TOZED ZLT S12 PRO

The TOZED ZLT S12 PRO is an AC1200 router featuring 4 Ethernet ports with a
TOZED TL70-C cellular modem which supports the NCM mode.

The stock firmware does SIM locking on the modem by stopping dialing when a
different PLMN is detected. This is not the case on OpenWrt.

Specifications:
- CPU: MediaTek MT7621AT
- RAM: 256MB DDR3
- NOR Flash: MX25L12833FM2I 16MB SPI Flash
- Wi-Fi 2.4Ghz: MT7603E
- Wi-Fi 5Ghz: MT7612E
- Switch: MT7530 4x 1Gbit Ports
- WWAN: Unisoc SL8563 based TOZED TL70-C LTE CAT6 cellular modem
- USB: 1x optional USB2.0 external port
- Switches/Buttons: WPS, Reset, Power Switch
- LEDs: Power, Wi-Fi, Data, Signal 1-5, Phone

Installation and TFTP Recovery:
- Connect to serial console.
- Boot initramfs image by choosing option 1 when U-Boot prompts.
- Install sysupgrade image via OpenWrt.

Serial Pins:
Located at the bottom right when looking from the front, right under the
Reset/WPS buttons. The pinout from the left is:
- RX
- GND
- TX
Baudrate is 115200.

When connecting from a powered off state, disconnect RX as it blocks the
boot process.

Link: http://www.sztozed.com/en/contents/58/84.html
Co-developed-by: Andre Cruz <me@1conan.com>
Signed-off-by: Andre Cruz <me@1conan.com>
Signed-off-by: Arınç ÜNAL <arinc.unal@arinc9.com>
18 months agocomgt-ncm: add support for UNISOC SL8563 based TOZED TL70-C
Arınç ÜNAL [Mon, 17 Apr 2023 20:11:29 +0000 (23:11 +0300)]
comgt-ncm: add support for UNISOC SL8563 based TOZED TL70-C

TOZED TL70-C is an LTE CAT6 cellular modem based on UNISOC SL8563. UNISOC
was formerly called Spreadtrum hence the manufacturer name detected on the
modem is spreadtrum.

The connect and disconnect commands bring up and down the usb0 interface.
They are Base64 encoded as that's what the AT command accepts. The modem
can do up to 4 APNs by bringing the USB interfaces, usb0 to usb3, up.

Setting the USB interfaces up:

connmanctl ndisdial AT^NDISDUN="usb0",1,1
connmanctl ndisdial AT^NDISDUN="usb1",1,2
connmanctl ndisdial AT^NDISDUN="usb2",1,3
connmanctl ndisdial AT^NDISDUN="usb3",1,4

Setting the USB interfaces down:

connmanctl ndisdial AT^NDISDUN="usb0",0,1
connmanctl ndisdial AT^NDISDUN="usb1",0,2
connmanctl ndisdial AT^NDISDUN="usb2",0,3
connmanctl ndisdial AT^NDISDUN="usb3",0,4

Co-developed-by: Andre Cruz <me@1conan.com>
Signed-off-by: Andre Cruz <me@1conan.com>
Signed-off-by: Arınç ÜNAL <arinc.unal@arinc9.com>
18 months agobase-files: add protocol ncm support for ucidef_set_interface()
Arınç ÜNAL [Thu, 11 May 2023 23:50:43 +0000 (01:50 +0200)]
base-files: add protocol ncm support for ucidef_set_interface()

Make it possible to set up a default network (interface) for devices with
cellular modems using NCM.

Signed-off-by: Arınç ÜNAL <arinc.unal@arinc9.com>
18 months agowwan: add Medion S4222 usb lte stick
Joe Cooper [Mon, 15 May 2023 21:49:59 +0000 (23:49 +0200)]
wwan: add Medion S4222 usb lte stick

add description for medion usb lte webstick

Signed-off-by: Joe Cooper <highjagger+github@gmail.com>
[bump PKG_RELEASE]
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
18 months agoucode: update to the latest version
Tianling Shen [Sat, 13 May 2023 13:57:00 +0000 (21:57 +0800)]
ucode: update to the latest version

8f78aff2cb68 ubus: support multiple call return values
51f4dba67313 ucode: also link libresolv if ns_initparse() is not found
5c7d07773a59 uci: fix ctx.commit() without arguments
5163867269fc Merge pull request #148 from jow-/uci-fix-commit

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
18 months agomediatek: remove left-over reference to make_gl_metadata.py
Daniel Golle [Thu, 18 May 2023 10:21:48 +0000 (11:21 +0100)]
mediatek: remove left-over reference to make_gl_metadata.py

When adding support for the GL.iNet GL-MT3000 a reference to the
non-existent make_gl_metadata.py script was accidentally added.
Remove it, flashing from vendor firmware also works fine without that.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
18 months agoramips: Fix Wireless Frequencies for HYC-G920
Muhammad AL-Qadhy [Sun, 7 May 2023 13:37:51 +0000 (16:37 +0300)]
ramips: Fix Wireless Frequencies for HYC-G920

Fix wireless frequencies to show correct wireless interfaces.

Signed-off-by: Muhammad AL-Qadhy <m.ismael@gmail.com>
18 months agopx5g-wolfssl: replace COMMITCOUNT with real PKG_RELEASE
Tianling Shen [Wed, 17 May 2023 13:14:25 +0000 (21:14 +0800)]
px5g-wolfssl: replace COMMITCOUNT with real PKG_RELEASE

Similar to the AUTORELEASE conversion process.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
18 months agotreewide: replace AUTORELEASE with real PKG_RELEASE
Tianling Shen [Wed, 17 May 2023 13:08:40 +0000 (21:08 +0800)]
treewide: replace AUTORELEASE with real PKG_RELEASE

Based on Paul Fertser <fercerpav@gmail.com>'s guidance:
Change AUTORELEASE in rules.mk to:
```
AUTORELEASE = $(if $(DUMP),0,$(shell sed -i "s/\$$(AUTORELEASE)/$(call commitcount,1)/" $(CURDIR)/Makefile))
```

then update all affected packages by:
```
for i in $(git grep -l PKG_RELEASE:=.*AUTORELEASE | sed 's^.*/\([^/]*\)/Makefile^\1^';);
do
make package/$i/clean
done
```

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
18 months agofirmware-utils: update to latest HEAD
David Bauer [Thu, 18 May 2023 08:43:52 +0000 (10:43 +0200)]
firmware-utils: update to latest HEAD

02cdbc6 tplink-safeloader: add Archer AX23 v1.2 (RU)
de36fa6 tplink-safeloader: add AX23 support-list entry
5f6fefd tplink-safeloader: order AX23 support-list
25131d6 tplink-safeloader: add Archer C59 / C60 CA ragion code

Signed-off-by: David Bauer <mail@david-bauer.net>
18 months agolibselinux: update to 3.5
Linhui Liu [Sat, 13 May 2023 09:40:32 +0000 (17:40 +0800)]
libselinux: update to 3.5

Switch from libpcre to libpcre2. While working on it remove the double
defined HOST_BUILD_DEPENDS section.

Release Notes:
https://github.com/SELinuxProject/selinux/releases/download/3.4/RELEASE-3.4.txt
https://github.com/SELinuxProject/selinux/releases/download/3.5/RELEASE-3.5.txt

Signed-off-by: Linhui Liu <liulinhui36@gmail.com>
[depend on libpcre2]
Signed-off-by: Nick Hainke <vincent@systemli.org>
18 months agosecilc: update to 3.5
Linhui Liu [Sat, 13 May 2023 09:57:00 +0000 (17:57 +0800)]
secilc: update to 3.5

Release Notes:
https://github.com/SELinuxProject/selinux/releases/download/3.4/RELEASE-3.4.txt
https://github.com/SELinuxProject/selinux/releases/download/3.5/RELEASE-3.5.txt

Signed-off-by: Linhui Liu <liulinhui36@gmail.com>
18 months agopolicycoreutils: update to 3.5
Linhui Liu [Sat, 13 May 2023 09:54:56 +0000 (17:54 +0800)]
policycoreutils: update to 3.5

Release Notes:
https://github.com/SELinuxProject/selinux/releases/download/3.4/RELEASE-3.4.txt
https://github.com/SELinuxProject/selinux/releases/download/3.5/RELEASE-3.5.txt

Signed-off-by: Linhui Liu <liulinhui36@gmail.com>
18 months agolibsemanage: update to 3.5
Linhui Liu [Sat, 13 May 2023 09:43:31 +0000 (17:43 +0800)]
libsemanage: update to 3.5

Release Notes:
https://github.com/SELinuxProject/selinux/releases/download/3.4/RELEASE-3.4.txt
https://github.com/SELinuxProject/selinux/releases/download/3.5/RELEASE-3.5.txt

Signed-off-by: Linhui Liu <liulinhui36@gmail.com>
18 months agolibsepol: update to 3.5
Linhui Liu [Sat, 13 May 2023 09:47:04 +0000 (17:47 +0800)]
libsepol: update to 3.5

Release Notes:
https://github.com/SELinuxProject/selinux/releases/download/3.4/RELEASE-3.4.txt
https://github.com/SELinuxProject/selinux/releases/download/3.5/RELEASE-3.5.txt

Signed-off-by: Linhui Liu <liulinhui36@gmail.com>
18 months agocheckpolicy: update to 3.5
Linhui Liu [Sat, 13 May 2023 09:52:17 +0000 (17:52 +0800)]
checkpolicy: update to 3.5

Release Notes:
https://github.com/SELinuxProject/selinux/releases/download/3.4/RELEASE-3.4.txt
https://github.com/SELinuxProject/selinux/releases/download/3.5/RELEASE-3.5.txt

Signed-off-by: Linhui Liu <liulinhui36@gmail.com>
18 months agopcre: move package to packages feed
Nick Hainke [Wed, 17 May 2023 20:39:20 +0000 (22:39 +0200)]
pcre: move package to packages feed

With the update of selinux no package depends anymore on pcre in the
base repository. Move it to packages feed.

Signed-off-by: Nick Hainke <vincent@systemli.org>
18 months agopcre2: import pcre2 from packages feed
Nick Hainke [Wed, 17 May 2023 09:09:21 +0000 (11:09 +0200)]
pcre2: import pcre2 from packages feed

pcre2 is needed by newer selinux versions, so it needs to be in the base
repository.

Signed-off-by: Nick Hainke <vincent@systemli.org>
18 months agoci: fix check kernel patches job
Petr Štetiar [Wed, 17 May 2023 20:08:12 +0000 (22:08 +0200)]
ci: fix check kernel patches job

Currently the check fails due to the following error:

 warning: Not a git repository. Use --no-index to compare two paths outside a working tree
 usage: git diff --no-index [<options>] <path> <path>

Thats likely caused by commit 1cb8cdbf0723 ("ci: use new buildbot worker
images with Debian 11") which contains a patched Git version with CVE
security fixes introduced in DLA-3239-2:

 Multiple issues were found in Git, a distributed revision control
 system. An attacker may cause other local users into executing arbitrary
 commands, leak information from the local filesystem, and bypass
 restricted shell.

 Note: Due to new security checks, access to repositories owned and
 accessed by different local users may now be rejected by Git; in case
 changing ownership is not practical, git displays a way to bypass these
 checks using the new "safe.directory" configuration entry.

So lets opt-out of this new behavior by setting `safe.directory=*` and
thus force Git to consider all Git repositories as safe regardless of
their owner, since we need to trust those sources anyway and it should
be likely more robust solution, then fiddling with filesystem
permissions.

Fixes: 1cb8cdbf0723 ("ci: use new buildbot worker images with Debian 11")
References: https://www.debian.org/lts/security/2022/dla-3239-2
Signed-off-by: Petr Štetiar <ynezz@true.cz>
18 months agomediatek: update patch add PWM support for MT7981
Daniel Golle [Thu, 20 Apr 2023 17:34:47 +0000 (18:34 +0100)]
mediatek: update patch add PWM support for MT7981

Update patch with version submitted upstream.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
18 months agomediatek: add support for the GL.iNet GL-MT3000
Daniel Golle [Sat, 11 Mar 2023 03:56:35 +0000 (03:56 +0000)]
mediatek: add support for the GL.iNet GL-MT3000

The MT-3000 is a pocket-sized Wi-Fi 6 router based on MediaTek MT7981.

Specification:
 - SoC: MediaTek MT7981B
 - CPU: 2x 1.3 GHz Cortex-A53
 - Flash: 256 MiB Macronix SPI NAND
 - RAM: 512 MiB Nanya DDR4
 - WLAN: 2.4 GHz, 5 GHz (MediaTek MT7976CN)
 - Ethernet:
    - 1x 10/100/1000 Mbps built-in PHY (LAN)
    - 1x 10/100/1000/2500 Mbps MaxLinear GPY211 PHY (WAN)
 - USB 3.0 port
 - Buttons: 1 button, 1 switch
 - LEDs: 1x light-blue, 1x warm-white
 - Serial console: internal 4-pin header, 115200 8n1
 - PWM controlled fan with tacho
 - Power: 5 VDC, 3 A (USB Type-C)

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
18 months agomac80211: fix mt7601u firmware path and refresh patches
Daniel Golle [Mon, 15 May 2023 23:03:56 +0000 (01:03 +0200)]
mac80211: fix mt7601u firmware path and refresh patches

Import patch fixing the updated firmware path of mt7601u.bin.
Refresh patches while at it.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
18 months agomediatek: add support for Cudy WR3000 v1
David Bauer [Wed, 17 May 2023 13:55:42 +0000 (15:55 +0200)]
mediatek: add support for Cudy WR3000 v1

Hardware
--------
MediaTek MT7981 WiSoC
256MB DDR3 RAM
16MB SPI-NOR (XMC XM25QH128C)
MediaTek MT7981 2x2 DBDC 802.11ax 2T2R (2.4 / 5)
UART: 115200 8N1 3.3V
      [LEDS] VCC-GND-RX-TX [ETH]
      Header is located below the heatsink

Case
----
Unscrew the 4 bottom screws. Remove the top of the case by inserting a
small screwdriver into the ventilation holes and lift the top cover.

This works best by beginning near the ETH-ports. The top is clipped on
the front near the LEDs with two plastic clips. The back has a single
clip in the middle. Start at one of the back edges.

MAC-Addresses
-------------
80:AF:CA:00:F9:C6 LAN
80:AF:CA:00:F9:C7 WAN
80:AF:CA:00:F9:C6 W2
82:AF:CA:30:F9:C6 W5

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

1. Connect to the serial port as described in the "Hardware" section.

2. Power on the device. Keep pressing the "0" key to enter the U-Boot
   shell.

3. Download the OpenWrt initramfs image. Place it on an TFTP server
   connected to the Cudy LAN ports. Make sure the server is reachable at
   192.168.1.2. Rename the image to "cudy3000.bin"

4. Download and boot the OpenWrt initramfs image.

   $ tftpboot 0x46000000 cudy3000.bin; bootm 0x46000000

5. Transfer the OpenWrt sysupgrade image to the device using scp.
   Install with sysupgrade.

Note: Cudy does not yet provide a image for disabling their
signature-protection. This has happened in the past. Make sure to check
the wiki for a possible easier installation method.

Signed-off-by: David Bauer <mail@david-bauer.net>
18 months agoiwinfo: update to latest HEAD
David Bauer [Wed, 17 May 2023 20:47:38 +0000 (22:47 +0200)]
iwinfo: update to latest HEAD

c9f5c3f devices: add MediaTek MT7981 WMAC compatible
b3888b2 devices: add compatible strings for Ralink WiSoCs

Signed-off-by: David Bauer <mail@david-bauer.net>
18 months agomt76: add MT7981 firmware packages
David Bauer [Wed, 17 May 2023 18:42:56 +0000 (20:42 +0200)]
mt76: add MT7981 firmware packages

Package the firmware required for MT7981 to bring up the radio.

Signed-off-by: David Bauer <mail@david-bauer.net>
18 months agomt76: update to latest HEAD
David Bauer [Wed, 17 May 2023 18:37:21 +0000 (20:37 +0200)]
mt76: update to latest HEAD

969b7b5e wifi: mt76: mt7915: add support for MT7981
cddbd796 linux-firmware: add firmware for MT7981
c69b0239 linux-firmware: update firmware for MT7921 WiFi device
c85a0f2f mt7921: remove duplicated line
0cbe1376 wifi: mt76: mt7915: drop redundant prefix of mt7915_txpower_puts()
b490c6c7 wifi: mt76: fix 6GHz high channel not be scanned
db5a8f70 wifi: mt76: move shared mac definitions in mt76_connac2_mac.h
3963ab2f wifi: mt76: mt7921: get rid of eeprom.h
c09f943d wifi: mt76: add mt76_connac_gen_ppe_thresh utility routine
28ea992c wifi: mt76: get rid of unused sta_ps callbacks
2936b036 wifi: mt76: add mt76_connac_irq_enable utility routine
482d2a76 wifi: mt76: move irq_tasklet in mt76_dev struct
88d1b002 wifi: mt76: mt7996: enable mesh HW amsdu/de-amsdu support
577fbd47 linux-firmware: update firmware for MT7916
32be54b5 linux-firmware: update firmware for MT7921 WiFi device
4e2fad04 linux-firmware: update firmware for MT7922 WiFi device
f8793b1a linux-firmware: update firmware for MT7921 WiFi device
91e6ad2a linux-firmware: update firmware for MT7921 WiFi device
b7a538a3 linux-firmware: update firmware for MT7922 WiFi device
e3b5a8cc wifi: mt76: mt7996: enable configured beacon tx rate
a18bf481 wifi: mt76: mt7996: enable BSS_CHANGED_MCAST_RATE support
f863beed wifi: mt76: mt7996: enable BSS_CHANGED_BASIC_RATES support
aedc10d5 wifi: mt76: connac: add nss calculation into mt76_connac2_mac_tx_rate_val()
84a227e5 wifi: mt76: connac: fix txd multicast rate setting
a0657180 wifi: mt76: mt7921e: stop chip reset worker in unregister hook
fd895347 wifi: mt76: mt7921e: improve reliability of dma reset
c9fa8d64 wifi: mt76: mt7921: fix missing unwind goto in `mt7921u_probe`
c1baa812 mt76: mt7921: fix kernel panic by accessing unallocated eeprom.data
ca180889 wifi: mt76: move mcu_uni_event and mcu_reg_event in common code
98fbca7a wifi: mt76: mt7996: enable coredump support
be1ff24e wifi: mt76: mt7996: add full system reset knobs into debugfs
b7a6c0ef wifi: mt76: mt7996: enable full system reset support
46f28e75 wifi: mt76: mt7921: enable p2p support
6a7e41c3 wifi: mt76: mt7921e: Set memory space enable in PCI_COMMAND if unset
084e6de7 wifi: mt76: mt7921: use driver flags rather than mac80211 flags to mcu
c66e7a1a wifi: mt76: mt7921: introduce mt7921_get_mac80211_ops utility routine
821caac5 wifi: mt76: mt7996: fix eeprom tx path bitfields
9ae2569b wifi: mt76: mt7996: remove mt7996_mcu_set_pm()
3244d176 wifi: mt76: mt7996: init mpdu density cap
210a558a wifi: mt76: mt7996: fix pointer calculation in ie countdown event
207c92bb wifi: mt76: mt7996: remove unused eeprom band selection
16a24667 wifi: mt76: mt7996: let non-bufferable MMPDUs use correct hw queue
d39bb7c8 wifi: mt76: mt7996: remove mt7996_mcu_beacon_check_caps()
4046b591 wifi: mt76: mt7915: remove mt7915_mcu_beacon_check_caps()
d63cb85c wifi: mt76: add missing locking to protect against concurrent rx/status calls
22f1b777 mt76: adjust for ieee80211_is_bufferable_mmpdu API change
8ecf551c wifi: mt76: set NL80211_EXT_FEATURE_CAN_REPLACE_PTK0 on supported drivers
efa44cb5 wifi: mt76: ignore key disable commands
56f0cd4d wifi: mt76: mt7915 add tc offloading support
021ded36 tools: Fix compile error with glibc

Signed-off-by: David Bauer <mail@david-bauer.net>
18 months agomediatek: fix typo
David Bauer [Wed, 17 May 2023 20:51:58 +0000 (22:51 +0200)]
mediatek: fix typo

Signed-off-by: David Bauer <mail@david-bauer.net>
18 months agobmips: improve kernel patches
Álvaro Fernández Rojas [Wed, 17 May 2023 16:03:33 +0000 (18:03 +0200)]
bmips: improve kernel patches

Add missing patch headers and regenerate the ones that contain an obsolete
patch header.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
18 months agomdadm: fix compilation with musl 1.2.4
Nick Hainke [Tue, 16 May 2023 18:07:38 +0000 (20:07 +0200)]
mdadm: fix compilation with musl 1.2.4

_LARGEFILE64_SOURCE has to be defined in the source, or CFLAGS can be used
to pass -D_LARGEFILE64_SOURCE to allow to keep using LFS64 definitions.

Fixes error in the form of:
restripe.c: In function 'restore_stripes':
restripe.c:758:43: error: 'off64_t' undeclared (first use in this function); did you mean 'off_t'?
  758 |                                          (off64_t)read_offset) {
      |                                           ^~~~~~~
      |                                           off_t
restripe.c:758:43: note: each undeclared identifier is reported only once for each function it appears in
restripe.c:758:51: error: expected ')' before 'read_offset'
  758 |                                          (off64_t)read_offset) {
      |                                                   ^~~~~~~~~~~
      |                                                   )
restripe.c:757:36: note: to match this '('
  757 |                                 if (lseek64(source, read_offset, 0) !=
      |                                    ^
make[3]: *** [Makefile:193: restripe.o] Error 1

Fixes: fff878c5bcda ("toolchain/musl: update to 1.2.4")
Signed-off-by: Nick Hainke <vincent@systemli.org>
18 months agoe2fsprogs: fix compilation with musl 1.2.4
Tianling Shen [Tue, 16 May 2023 07:49:08 +0000 (15:49 +0800)]
e2fsprogs: fix compilation with musl 1.2.4

musl 1.2.4 deprecated legacy "LFS64" ("large file support") interfaces and
autotools failed to check the lseek64 function.

Force enable ac_cv_func_lseek64 to workaround it.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
18 months agof2fs-tools: fix compilation with musl 1.2.4
Tianling Shen [Tue, 16 May 2023 11:03:29 +0000 (19:03 +0800)]
f2fs-tools: fix compilation with musl 1.2.4

musl 1.2.4 deprecated legacy "LFS64" ("large file support") interfaces and
autotools failed to check the lseek64 function.

Force enable ac_cv_func_lseek64 to workaround it.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
18 months agoath79: add support for MikroTik RB951Ui-2HnD
Michał Kępień [Tue, 18 Apr 2023 13:48:41 +0000 (15:48 +0200)]
ath79: add support for MikroTik RB951Ui-2HnD

MikroTik RB951Ui-2HnD is a wireless SOHO router that was previously
supported by the ar71xx target, see commit d19b868b12 ("ar71xx: Add
support for MikroTik RB951Ui-2HnD").

Specifications
--------------

  - SoC: Atheros AR9344 (600 MHz)
  - RAM: 128 MB (2x 64 MB)
  - Storage: 128 MB NAND flash (various manufacturers)
  - Ethernet: Atheros AR8229 switch, 5x 10/100 Mbit/s
      - 1x PoE in (port 1, 8-30 V input)
      - 1x PoE out (port 5, 500 mA output)
  - Wireless: Atheros AR9340 (802.11b/g/n)
  - USB: 2.0 (1A)
  - 9x LED:
      - 1x power (green, not configurable)
      - 1x user (green)
      - 5x FE ports (green)
      - 1x wireless (green)
      - 1x PoE out (red)
  - 1x button (restart)

See https://mikrotik.com/product/RB951Ui-2HnD for more details.

Flashing
--------

TFTP boot initramfs image and then perform sysupgrade.  Follow
common MikroTik procedures at https://openwrt.org/toh/mikrotik/common.

Signed-off-by: Michał Kępień <openwrt@kempniu.pl>
18 months agolibbsd: fix compilation with musl 1.2.4
Robert Marko [Tue, 16 May 2023 08:48:28 +0000 (10:48 +0200)]
libbsd: fix compilation with musl 1.2.4

musl 1.2.4 deprecated legacy "LFS64" ("large file support") interfaces so
just having _GNU_SOURCE defined is not enough anymore.

_LARGEFILE64_SOURCE has to be defined in the source, or CFLAGS can be used
to pass -D_LARGEFILE64_SOURCE to allow to keep using LFS64 definitions.

Fixes: fff878c5bcda ("toolchain/musl: update to 1.2.4")
Signed-off-by: Robert Marko <robimarko@gmail.com>
18 months agolinux-firmware: move firmware file for mt7601u
Daniel Golle [Mon, 15 May 2023 19:56:27 +0000 (21:56 +0200)]
linux-firmware: move firmware file for mt7601u

The firmware file for mt7601u (MediaTek MT7601U Wireless MACs) has
been moved to the mediatek/ folder by commit
 8451c2b1 mt76xx: Move the old Mediatek WiFi firmware to mediatek

Address this by updating the location of the firmware file in our
linux-firmware Makefile generating the mt7601u-firmware package.

All other MediaTek Wi-Fi firmware files are supplied by OpenWrt's
own repository rather than being taken from linux-firmware.

Fixes: d53fe5d9ce ("linux-firmware: update to 20230515")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
18 months agolinux-firmware: update to 20230515
Daniel Golle [Mon, 15 May 2023 18:47:21 +0000 (20:47 +0200)]
linux-firmware: update to 20230515

Package offloading firmware for MT7981 which has been added to
linux-firmware recently and became available in this release.

Changes since 20230515:
51290942 Merge branch 'main' of https://github.com/CirrusLogic/linux-firmware
cc628d65 cirrus: Add firmware and tuning files for HP G10 series laptops
905d3265 linux-firmware: update firmware for mediatek bluetooth chip (MT7922)
d1962891 WHENCE: Cleanup Realtek BT firmware provenance
6569484e linux-firmware: update firmware for MT7922 WiFi device
7d639e80 cnm: update chips&media wave521c firmware.
b8a56bf2 cirrus: Add firmware and tuning files for Lenovo ThinkPad P1 Gen 6
6c9e0ed5 check_whence: error on directory listed as File
05183b7b check_whence: error on duplicate file entries
c4423c91 WHENCE: comment out duplicate MediaTek firmware
2bc50f50 Merge branch 'mtl_guc_70.6.6' of git://anongit.freedesktop.org/drm/drm-firmware
192ee6d1 i915: Add GuC v70.6.6 for MTL
312c61f5 amdgpu: update DCN 3.1.6 DMCUB firmware
0061a2dd rtl_bt: Update RTL8852B BT USB firmware to 0xDBC6_B20F
1de22a39 rtl_bt: Update RTL8761B BT USB firmware to 0xDFC6_D922
dee0d4cd rtl_bt: Update RTL8761B BT UART firmware to 0x9DC6_D922
fab14965 Group all Conexant V4L devices together
e88bdbe4 rtl_nic: update firmware of USB devices
6536a964 linux-firmware: Update firmware file for Intel Bluetooth AX200
2ca17876 linux-firmware: Update firmware file for Intel Bluetooth AX201
7610656f linux-firmware: Update firmware file for Intel Bluetooth AX203
209ba083 linux-firmware: Update firmware file for Intel Bluetooth AX203
a2739f05 linux-firmware: Update firmware file for Intel Bluetooth AX211
1ee587d5 linux-firmware: Update firmware file for Intel Bluetooth AX211
40ba7eee linux-firmware: Update firmware file for Intel Bluetooth AX210
bcbbf6bf linux-firmware: update firmware for MT7981
507ee862 Merge branch 'main' of github.com:sampathnimmmala/bt_firmware
2c6be1a4 qca: Update firmware files for BT chip WCN6750
8451c2b1 mt76xx: Move the old Mediatek WiFi firmware to mediatek
53e48f93 rtl_bt: Add firmware and config files for RTL8851B
69143e8e linux-firmware: Update AMD cpu microcode
1c942e46 Merge branch 'for-upstream' of https://github.com/CirrusLogic/linux-firmware
45530bcb linux-firmware: add firmware for MT7981
0d02ce69 linux-firmware: update firmware for MT7921 WiFi device
2deb2d30 linux-firmware: update firmware for mediatek bluetooth chip (MT7921)
9fdb844b linux-firmware: update qat firmware
74afc00d linux-firmware: Add firmware for Cirrus CS35L41 on Lenovo Laptops
86da2ac9 Merge https://github.com/pkshih/linux-firmware
5d0d24b3 linux-firmware: update firmware for MT7916
0aea9cdf Merge branch 'ath10k-20230405' of git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/linux-firmware
9f7502f1 rtw89: 8852b: update format-1 fw to v0.29.29.1
b9c8e9f7 rtw89: 8852c: update fw to v0.27.56.13
d1dc3048 ath11k: WCN6855 hw2.0: update board-2.bin
8115bd84 ath11k: WCN6750 hw1.0: update to WLAN.MSL.1.0.1-01160-QCAMSLSWPLZ-1
7d2ab030 ath11k: QCN9074 hw1.0: update to WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1
b58b0869 ath11k: IPQ8074 hw2.0: update to WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1
0747362d ath11k: IPQ8074 hw2.0: update board-2.bin
7262bd5d ath11k: IPQ6018 hw1.0: update to WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1
aa98ffa3 ath11k: IPQ6018 hw1.0: update board-2.bin
2c67adc9 ath10k: QCA99X0 hw2.0: update board-2.bin
a5dcb441 ath10k: QCA9984 hw1.0: update board-2.bin
d0731d40 ath10k: QCA9888 hw2.0: update board-2.bin
e13fedda ath10k: QCA6174 hw3.0: update board-2.bin
465dc284 ath10k: QCA4019 hw1.0: update board-2.bin
2e92a49f nvidia: update Tu10x and Tu11x signed firmware to support newer Turing HW
00258371 linux-firmware: update firmware for MT7922 WiFi device
33d8bf79 linux-firmware: update firmware for mediatek bluetooth chip (MT7922)
87bb6c9a Merge tag 'iwlwifi-fw-2023-03-30' of http://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/linux-firmware
956c1163 Merge branch 'mlimonci/update-dcn-3-1-4' of https://gitlab.freedesktop.org/superm1/linux-firmware
717e62eb linux-firmware: Amphion: Update vpu firmware
7bce2920 Merge https://github.com/pkshih/linux-firmware
78a8782a iwlwifi: add new FWs from core78-32 release
a91d0e78 iwlwifi: update 9000-family firmwares to core78-32
9ee24ce0 amdgpu: Update SDMA 6.0.1 firmware
7df2a1ae amdgpu: Add PSP 13.0.11 firmware
f098803d amdgpu: Update PSP 13.0.4 firmware
2cc9a4d0 amdgpu: Update GC 11.0.1 firmware
eb13e669 amdgpu: Update DCN 3.1.4 firmware
898b7def amdgpu: Add GC 11.0.4 firmware
e40a5b63 rtw88: 8822c: Update normal firmware to v9.9.15
bcdcfbcf linux-firmware: Update firmware file for Intel Bluetooth AX101
b422cdd6 linux-firmware: Update firmware file for Intel Bluetooth 9462
3e4c3b8d linux-firmware: Update firmware file for Intel Bluetooth 9462
6fcdb8e7 linux-firmware: Update firmware file for Intel Bluetooth 9560
46384d1c linux-firmware: Update firmware file for Intel Bluetooth 9560
1d797f86 linux-firmware: Update firmware file for Intel Bluetooth AX203
53c086b3 linux-firmware: Update firmware file for Intel Bluetooth AX203
9cc9745d linux-firmware: Update firmware file for Intel Bluetooth AX211
45319be8 linux-firmware: Update firmware file for Intel Bluetooth AX211
61d58194 linux-firmware: Update firmware file for Intel Bluetooth AX210
7f490a9a Merge branch 'dmc-adlp_2.19-mtl_2.12' of git://anongit.freedesktop.org/drm/drm-firmware
dcac1477 Merge branch 'mtk-20230315' of https://github.com/tinghan-shen/linux_fw_scp
1f82dd25 linux-firmware: add firmware files for NXP BT chipsets
49ad74b3 Merge https://github.com/pkshih/linux-firmware
2c07f017 rtw89: 8852b: update format-1 fw to v0.29.29.0
b50cf920 rtw89: 8852b: add format-1 fw v0.29.26.0
416a66ca rtw89: 8852b: rollback firmware to v0.27.32.1
a18a444b i915: Update MTL DMC to v2.12
4ee236db i915: Update ADLP DMC to v2.19
d0997ff6 mediatek: Update mt8192/mt8195 SCP firmware to support MM21 and MT21
c761dbe8 Merge tag 'iwlwifi-fw-2023-03-13' of http://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/linux-firmware
5bc279fb iwlwifi: update core69 and core72 firmwares for So device

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
18 months agogeneric: mtk_eth_soc: don't crash if WO firmware is missing
Daniel Golle [Tue, 9 May 2023 00:13:59 +0000 (02:13 +0200)]
generic: mtk_eth_soc: don't crash if WO firmware is missing

Import patch to prevent crashes in case WO firmware is missing on devices
with only a single frontend (eg. MT7981+MT7976).

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
18 months agogeneric: add support for wireless offloading on MT7981
Daniel Golle [Wed, 19 Apr 2023 18:47:40 +0000 (19:47 +0100)]
generic: add support for wireless offloading on MT7981

Load appropriate firmware for wireless offloading on MT7981.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
18 months agoci: use new buildbot worker images with Debian 11
Petr Štetiar [Mon, 15 May 2023 15:52:16 +0000 (17:52 +0200)]
ci: use new buildbot worker images with Debian 11

Debian 10 LTS support ends on 6/2024, so it makes no sense to use it as
a base for 23.05 release, so lets switch to Debian 11 which should've
LTS support till 6/2026.

References: https://github.com/openwrt/buildbot/commit/f2744543fa8027117b254ba2f4fa4366149d5bfb
Signed-off-by: Petr Štetiar <ynezz@true.cz>
18 months agolibselinux: fix compilation with musl 1.2.4
Robert Marko [Mon, 8 May 2023 10:47:29 +0000 (12:47 +0200)]
libselinux: fix compilation with musl 1.2.4

musl 1.2.4 deprecated legacy "LFS64" ("large file support") interfaces so
just having _GNU_SOURCE defined is not enough anymore.

_LARGEFILE64_SOURCE has to be defined in the source, or CFLAGS can be used
to pass -D_LARGEFILE64_SOURCE to allow to keep using LFS64 definitions.

Signed-off-by: Robert Marko <robimarko@gmail.com>
18 months agotoolchain/musl: update to 1.2.4
Linhui Liu [Sun, 7 May 2023 08:05:45 +0000 (16:05 +0800)]
toolchain/musl: update to 1.2.4

Release notes:

new features:
- large dns record lookups via tcp fallback
- new getaddrinfo EAI_NODATA result to distinguish NODATA/NxDomain
- support for new RELR compressed format for relative relocations
- sysconf keys for querying signal stack size requirements
- real vfork on riscv64

performance:
- mallocng no longer uses MADV_FREE (high performance cost, little gain)
- vdso clock_gettime is supported once again on 32-bit arm

compatibility:
- gethostbyname family now distinguishes NO_DATA from HOST_NOT_FOUND
- res_send now works with caller-provided edns0 queries
- arpa/nameser.h RR types list is now up-to-date
- previously-missing POSIX confstr keys have been added
- mntent interfaces now accept missing fields
- alt signal stack, if any, is now used for internal signals
- the LFS64 macros are no longer exposed without _LARGEFILE64_SOURCE
- memmem (POSIX-future) is now exposed in default feature profile
- pthread_atfork now admits calls from an application-provided malloc
- debugger tracking of shared libraries now works on MIPS PIE binaries
- sendmsg now supports up to SCM_MAX_FD fds in SCM_RIGHTS messages

bugs fixed:
- gethostbyname[2]_r wrongly returned nonzero (error) on negative result
- parallel v4/v6 address queries could fail on query id collisions
- spurious getaddrinfo/AI_ADDRCONFIG failures due to errno clobbering
- dns search domains ending in dot (including lone dot) broke lookups
- ipv6 servers in resolv.conf broke lookups on systems with v6 disabled
- systems with bindv6only failed to query both v4 and v6 nameservers
- res_mkquery mishandled consecutive final dots in name
- res_send could malfunction for very small answer buffer sizes
- resolver dns backend accepted answers with wrong (A vs AAAA) RR type
- getservbyport_r returned junk or ENOENT (vs ERANGE) on buffer size errors
- dns result parsing of malformed responses could process uninitialized data
- freopen didn't reset stream orientation (byte/wide) & encoding rule
- fwprintf didn't print most fields on open_wmemstream FILEs
- wide printf %lc ignored field width
- wide printf erroneously processed %n after encoding errors
- use of wide printf %9$ argument slot overflowed undersized buffer
- swprintf malfunctioned on nul character in output
- strverscmp ordered digit sequences vs nondigits incorrectly
- timer_create/SIGEV_THREAD failure leaked the thread
- semaphores were subject to missed-wake under certain usage patterns
- several possible rare deadlocks with lock handling at thread exit
- several possible rare deadlocks with aio and multithreaded fork
- dynamic linker relro processing was broken on archs w/variable pagesize
- async cancellation could run cancellation handlers in invalid context
- pthread_detach was wrongly a cancellation point in rare race code path
- use-after-close/double-close errors in mq_notify error paths
- mq_notify event thread wrongly ran with signals unmasked
- wcs{,n}cmp, wmemcmp returned wrong results when difference overflowed
- accept4, pipe2, and dup3 handled unknown flags wrong in fallback cases
- CPU_SETSIZE macro had wrong unit
- select fallback for pre-time64 kernels truncated timeout (vs clamping)

arch-specific bugs fixed:
- x32 new socketcalls took fallback path due to pointer sign extension
- x32 wait4 didn't fill rusage structure (time64 regression)
- x32 semtimedop mismatched timespec ABI with kernel (time64 regression)
- sigaction signal mask was bogus on or1k, microblaze, mips, and riscv
- powerpc-sf longjmp asm clobbered value argument
- or1k poll function passed timeout to syscall in wrong form

Removed upstreamed:
- 800-mips_pie_debug.patch
Manually rebased:
- 600-nftw-support-common-gnu-extension.patch

Signed-off-by: Linhui Liu <liulinhui36@gmail.com>
18 months agogettext-full: link to local libunistring
Michael Pratt [Sat, 13 May 2023 22:53:00 +0000 (18:53 -0400)]
gettext-full: link to local libunistring

Configure gettext to require and link
to our local libunistring explicitly.

Signed-off-by: Michael Pratt <mcpratt@pm.me>
18 months agogettext-full: add missing link to libunistring
Michael Pratt [Sat, 13 May 2023 22:55:44 +0000 (18:55 -0400)]
gettext-full: add missing link to libunistring

Running autoreconf or autogen.sh is causing
the gettext-runtime subdirectory to have a configure script
that looks for and attempts to link to an external libunistring.
However, the macros and symbols for supporting that configuration
are not present in this subdirectory yet.

This results in some host machines to not build the
included libunistring objects for libgrt,
but at the same time, also not input the proper flag to the linker
for linking to an external library when it is found or even when
explicitly setting configuration to use a prefix for libunistring,
resulting in the common linking failure "undefined reference".

Some similar (and old...) upstream commits do the same thing,
but only for gettext-tools and libgettextpo.

Ref: ae943bcc1 ("Link with libunistring, if it exists.") # gettext.git
Ref: 61e21a72f ("Avoid link error in programs that use libgettextpo.") # gettext.git
Signed-off-by: Michael Pratt <mcpratt@pm.me>
18 months agolibunistring: add from packages feed
Michael Pratt [Fri, 12 May 2023 07:48:47 +0000 (03:48 -0400)]
libunistring: add from packages feed

Add libunistring in order to link to gettext
and other packages directly
instead of the built-in substitute for it.

Signed-off-by: Michael Pratt <mcpratt@pm.me>
18 months agoath79: mikrotik: bump compat version for yafut images
Thibaut VARÈNE [Fri, 5 May 2023 12:54:03 +0000 (14:54 +0200)]
ath79: mikrotik: bump compat version for yafut images

Following 5264296, Mirotik NAND devices now use yafut to flash the
kernel on devices. This method is incompatible with the old-style
"kernel2minor" flash mechanism.

Even though NAND images were disabled in default build since 21.02, a
user flashing a new-style image onto an old-style image would result in
in a soft-brick[1]. In order to prevent such accidental mishap,
especially as these device images will be reenabled in the upcoming
release, bump the compat version.

After the new image is flashed, the compat version can be updated:

    uci set system.@system[0].compat_version='1.1'
    uci commit

[1] https://github.com/openwrt/openwrt/pull/12225#issuecomment-1517529262

Cc: Michał Kępień <openwrt@kempniu.pl>
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
Reviewed-by: Robert Marko <robimarko@gmail.com>
18 months agoethtool: update to 6.3
Nick Hainke [Mon, 15 May 2023 10:28:24 +0000 (12:28 +0200)]
ethtool: update to 6.3

Release Notes:
https://lore.kernel.org/netdev/20230508213111.z4vjg6gyrm7nwz4r@lion.mk-sys.cz/

Signed-off-by: Nick Hainke <vincent@systemli.org>
18 months agostrace: update to 6.3
Nick Hainke [Sun, 14 May 2023 12:16:02 +0000 (14:16 +0200)]
strace: update to 6.3

Release Notes:
https://github.com/strace/strace/releases/tag/v6.3

Signed-off-by: Nick Hainke <vincent@systemli.org>
18 months agokernel: ltq-ptm: fix compilation warning for vr9
Christian Marangi [Sun, 14 May 2023 16:01:20 +0000 (18:01 +0200)]
kernel: ltq-ptm: fix compilation warning for vr9

Fix compilation warning for unused variable for vr9.
Fix compilation warning:
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/ltq-ptm-vr9/ltq-ptm/ifxmips_ptm_vdsl.c: In function 'mailbox_irq_handler':
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/ltq-ptm-vr9/ltq-ptm/ifxmips_ptm_vdsl.c:560:9: error: unused variable 'i' [-Werror=unused-variable]
  560 |     int i;
      |         ^
cc1: all warnings being treated as errors

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
18 months agobcm47xx: Refresh patches
Hauke Mehrtens [Sun, 14 May 2023 14:28:41 +0000 (16:28 +0200)]
bcm47xx: Refresh patches

Refresh patches to make them cleanly apply.
This problem  was found by the github CI.

Fixes: ecd9abc8c082 ("kernel: use upstream firmware patch for Broadcom's NVRAM")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
18 months agokernel: backport NVMEM patch for Broadcom's NVRAM MAC cells
Rafał Miłecki [Sun, 14 May 2023 10:14:14 +0000 (12:14 +0200)]
kernel: backport NVMEM patch for Broadcom's NVRAM MAC cells

It has just been queued for the v6.5. It allows Ethernet drivers to read
MACs from NVRAM using NVMEM interface.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
18 months agokernel: use upstream firmware patch for Broadcom's NVRAM
Rafał Miłecki [Sun, 14 May 2023 10:08:09 +0000 (12:08 +0200)]
kernel: use upstream firmware patch for Broadcom's NVRAM

This replaces our 2 downstream patches.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
18 months agokernel: ltq-vdsl-vr9: fix multiple compilation warning
Christian Marangi [Sun, 14 May 2023 00:36:35 +0000 (02:36 +0200)]
kernel: ltq-vdsl-vr9: fix multiple compilation warning

Fix multiple compilation warning for fallthrough and unused functions.
Fix compilation warning:
home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/device/drv_dsl_cpe_device_vrx.c: In function 'DSL_DRV_VRX_TestParametersFeUpdate':
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/device/drv_dsl_cpe_device_vrx.c:3359:17: error: unused variable 'nMsgId' [-Werror=unused-variable]
 3359 |    DSL_uint16_t nMsgId = EVT_PMD_TESTPARAMSGET;
      |                 ^~~~~~
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/device/drv_dsl_cpe_device_vrx.c: In function 'DSL_DRV_DEV_AutobootHandleTraining':
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/device/drv_dsl_cpe_device_vrx.c:8310:19: error: this statement may fall through [-Werror=implicit-fallthrough=]
 8310 |          bPreFail = DSL_TRUE;
      |          ~~~~~~~~~^~~~~~~~~~
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/device/drv_dsl_cpe_device_vrx.c:8316:7: note: here
 8316 |       case DSL_LINESTATE_EXCEPTION:
      |       ^~~~
cc1: all warnings being treated as errors

/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/pm/drv_dsl_cpe_pm_core.c: In function 'DSL_DRV_PM_CountersReset':
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/pm/drv_dsl_cpe_pm_core.c:2328:7: error: this statement may fall through [-Werror=implicit-fallthrough=]
 2328 |    if (ResetType == DSL_PM_RESET_HISTORY)
      |       ^
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/pm/drv_dsl_cpe_pm_core.c:2331:4: note: here
 2331 |    case DSL_PM_RESET_TOTAL:
      |    ^~~~
cc1: all warnings being treated as errors

/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/common/drv_dsl_cpe_os_linux.c: In function 'DSL_ModuleCleanup':
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/common/drv_dsl_cpe_os_linux.c:1266:13: error: assignment to 'dev_t' {aka 'unsigned int'} from 'void *' makes integer from pointer without a cast [-Werror=int-conversion]
 1266 |    dsl_devt = NULL;
      |             ^
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/common/drv_dsl_cpe_os_linux.c: At top level:
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/common/drv_dsl_cpe_os_linux.c:1178:13: error: 'DSL_DRV_NlSendMsg' defined but not used [-Werror=unused-function]
 1178 | static void DSL_DRV_NlSendMsg(DSL_char_t* pMsg)
      |             ^~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors

/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_dsl_cpe_api-4.17.18.6/src/device/drv_dsl_cpe_msg_vrx.c:2459:20: error: 'DSL_DRV_VRX_SpreadArray' defined but not used [-Werror=unused-function]
 2459 | static DSL_Error_t DSL_DRV_VRX_SpreadArray(
      |                    ^~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
18 months agokernel: ltq-vdsl-vr9-mei: fix compilation warning
Christian Marangi [Sun, 14 May 2023 00:34:58 +0000 (02:34 +0200)]
kernel: ltq-vdsl-vr9-mei: fix compilation warning

Fix simple compilation warning due to cast and wrong include.
Fix compilation warning:
In file included from ./include/linux/compat.h:18,
                 from ./include/linux/filter.h:10,
                 from ./include/net/sock.h:59,
                 from /home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_mei_cpe-1.5.17.6/src/drv_mei_cpe_linux.c:70:
./include/uapi/linux/aio_abi.h:77:45: error: "__LITTLE_ENDIAN" is not defined, evaluates to 0 [-Werror=undef]
   77 | #if defined(__BYTE_ORDER) ? __BYTE_ORDER == __LITTLE_ENDIAN : defined(__LITTLE_ENDIAN)
      |                                             ^~~~~~~~~~~~~~~
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_mei_cpe-1.5.17.6/src/drv_mei_cpe_linux.c: In function 'MEI_MeminfoProcPerDevGet':
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_mei_cpe-1.5.17.6/src/drv_mei_cpe_linux.c:1715:56: error: format '%X' expects argument of type 'unsigned int', but argument 4 has type 'IFX_uint8_t *' {aka 'unsigned char *'} [-Werror=format=]
 1715 |                seq_printf(s, "chunk[%02d]: addr = 0x%08X (0x%08X), "
      |                                                     ~~~^
      |                                                        |
      |                                                        unsigned int
      |                                                     %08hhn
......
 1721 |                      chunkIdx, pChunk[chunkIdx].pImageChunk_aligned,
      |                                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                                                |
      |                                                IFX_uint8_t * {aka unsigned char *}
/home/ansuel/openwrt-ansuel/openwrt/build_dir/target-mips-openwrt-linux-musl_musl/linux-lantiq_xrx200/drv_mei_cpe-1.5.17.6/src/drv_mei_cpe_linux.c:1715:64: error: format '%X' expects argument of type 'unsigned int', but argument 5 has type 'IFX_uint8_t *' {aka 'unsigned char *'} [-Werror=format=]
 1715 |                seq_printf(s, "chunk[%02d]: addr = 0x%08X (0x%08X), "
      |                                                             ~~~^
      |                                                                |
      |                                                                unsigned int
      |                                                             %08hhn
......
 1722 |                      pChunk[chunkIdx].pImageChunk_allocated,
      |                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                                      |
      |                                      IFX_uint8_t * {aka unsigned char *}
cc1: all warnings being treated as errors

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
18 months agokernel: ltq-vectoring: add patch fixing compilation warning
Christian Marangi [Sat, 13 May 2023 22:21:44 +0000 (00:21 +0200)]
kernel: ltq-vectoring: add patch fixing compilation warning

Add patch fixing compilation warning related to stack limit.
Fix compilation warning:
/builder/shared-workdir/build/build_dir/target-mips_24kc_musl/linux-lantiq_xrx200/ltq-vectoring-2019-05-20-4fa7ac30/src/vectoring/ifxmips_vectoring.c: In function 'proc_write_dbg':
/builder/shared-workdir/build/build_dir/target-mips_24kc_musl/linux-lantiq_xrx200/ltq-vectoring-2019-05-20-4fa7ac30/src/vectoring/ifxmips_vectoring.c:369:1: error: the frame size of 2088 bytes is larger than 1024 bytes [-Werror=frame-larger-than=]
  369 | }
      | ^
cc1: all warnings being treated as errors

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
18 months agompc85xx: add support for Aerohive BR200-WP
Pawel Dembicki [Wed, 12 Apr 2023 08:43:43 +0000 (10:43 +0200)]
mpc85xx: add support for Aerohive BR200-WP

The following adds the Aerohive BR200-WP router to OpenWrt under
the mpc85xx/p1010 subtarget.

Hardware:
- SoC: Freescale P1011
- NOR: Intel JS28F512M29EWH 64MB
- Memory: 2x Nanya NT5TU64M16GG-AC 128MB (Total of 256MB)
- 2.4GHz WiFi: Atheros AR9390-AL1A
- Eth1: Atheros AR8035-A PoE
- 2x LEDs
- 1x Button
- PoE PSE

Flashing:
1. Hook into UART (9600 baud) and enter U-Boot. You may need to enter a
password of administrator or AhNf?d@ta06 if prompted.
2. Once in U-Boot, tftp boot the initramfs image:
   dhcp; setenv serverip 192.168.1.3;
   tftpboot 0x2004000 openwrt-mpc85xx-p1010-aerohive_br200-wp-initramfs-kernel.bin;
   bootm 0x2004000;
3. Once booted, scp over the sysupgrade file and sysupgrade the device
to flash LEDE to the NOR.

Note:

MAC assigns are taken from stock firmware:

Name        MAC addr      Mode       State Chan(Width) VLAN   Radio      Hive       SSID
-------- -------------- --------     ----- ----------- ---- ---------- ---------- ---------
Mgt0     08ea:44XX:XXc0    -           U     -            1     -        hive0        -
Eth0     08ea:44XX:XXc0 wan            U     -            -     -          -          -
Eth1     08ea:44XX:XXc2 access         D     -            -     -        hive0        -
Eth2     08ea:44XX:XXc3 access         D     -            -     -        hive0        -
Eth3     08ea:44XX:XXc4 access         D     -            -     -        hive0        -
Eth4     08ea:44XX:XXc5 access         D     -            -     -        hive0        -
Wifi0    08ea:44XX:XXd0 access         U     1(20MHz)     -  radio_ng0     -          -
Wifi0.1  08ea:44XX:XXd4 access         D     1(20MHz)     -  radio_ng0   hive0        -

Note2:
PoE PSE could be managed with `realtek-poe` package. Example port
config:

config port
        option enable   '1'
        option id       '4'
        option name     'lan2'
        option poe_plus '0'
        option priority '2'
config port
        option enable   '1'
        option id       '3'
        option name     'lan1'
        option poe_plus '0'
        option priority '1'

Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
(switch@0 -> switch@10, Device's quickstart says LEDs are
amber and white => add function+color properties but keep
labels around, use pr_info)
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
18 months agokirkwood: Replace dtses with upstream accepted
Pawel Dembicki [Thu, 11 May 2023 15:02:43 +0000 (17:02 +0200)]
kirkwood: Replace dtses with upstream accepted

DTSes from of three boards was sent and accpeted upstream. Let's use
backport patches with small OpenWrt tweak like other upstream stuff.

List of boards:
  - Zyxel NSA310S
  - Endian 4i Edge 200
  - Ctera C-200 V1

Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
18 months agoath79: add Cisco Meraki MR18
Christian Lamparter [Fri, 30 Jul 2021 15:59:25 +0000 (17:59 +0200)]
ath79: add Cisco Meraki MR18

Specifications:

SOC:    Atheros/Qualcomm QCA9557-AT4A @ 720MHz
RAM:    2x Winbond W9751G6KB-25 (128 MiB)
FLASH:  Hynix H27U1G8F2BTR-BC TSOP48 ONFI NAND (128 MiB)
WIFI1:  Atheros AR9550 5.0GHz (SoC)
WIFI2:  Atheros AR9582-AR1A 2.4GHz
WIFI2:  Atheros AR9582-AR1A 2.4GHz + 5GHz
PHYETH: Atheros AR8035-A, 802.3af PoE capable Atheros (1x Gigabit LAN)
LED:    1x Power-LED, 1 x RGB Tricolor-LED
INPUT:  One Reset Button
UART:   JP1 on PCB (Labeled UART), 3.3v-Level, 115200n8
        (VCC, RX, TX, GND - VCC is closest to the boot set jumper
 under the console pins.)

Flashing instructions:

Depending on the installed firmware, there are vastly different
methods to flash a MR18. These have been documented on:
<https://openwrt.org/toh/meraki/mr18>

Tip:
Use an initramfs from a previous release and then use sysupgrade
to get to the later releases. This is because the initramfs can
no longer be built by the build-bots due to its size (>8 MiB).

Note on that:
Upgrades from AR71XX releases are possible, but they will
require the force sysupgrade option ( -F ).

Please backup your MR18's configuration before starting the
update. The reason here is that a lot of development happend
since AR71XX got removed, so I do advise to use the ( -n )
option for sysupgrade as well. This will cause the device
to drop the old AR71xx configuration and make a new
configurations from scratch.

Note on LEDs:
The LEDs has changed since AR71XX. The white LED is now used during
the boot and when upgrading instead of the green tricolor LED. The
technical reason is that currently the RGB-LED is brought up later
by a userspace daemon.

(added warning note about odm-caldata partition. remove initramfs -
it's too big to be built by the bots. MerakiNAND -> meraki-header.
sort nu801's targets)
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
18 months agoath79: ar934x: still advertise subpage on soft ecc
Christian Lamparter [Sat, 31 Jul 2021 01:33:03 +0000 (03:33 +0200)]
ath79: ar934x: still advertise subpage on soft ecc

This sort of reverts Koen Vandeputte's commit
6561ca1fa51 ("ath79: ar934x: fix mounting issues if subpage is not supported")

since it does not work on the MR18 as the UBI is coming from
Meraki in that way and it used to work with AR71XX before.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
18 months agoath79: nand: enable software BCH support
Christian Lamparter [Sat, 31 Jul 2021 21:16:05 +0000 (23:16 +0200)]
ath79: nand: enable software BCH support

This is necessary to support the Meraki MR18 and likely Z1
as well.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
18 months agoath79: set 2048B ECC size for Mikrotik boards using soft ECC
Lech Perczak [Mon, 1 May 2023 22:51:49 +0000 (00:51 +0200)]
ath79: set 2048B ECC size for Mikrotik boards using soft ECC

Two Mikrotik board families (SXT 5nD R2 and Routerboard 92x are using
software ECC on NAND. Some of them use chips capable of subpage write,
others do not - within the same family, and a common block size is
required for UBI, to avoid mounting errors. Set the ECC step size
explicitly for them to 2048B, so UBI can mount existing volumes without
problems, at the same time allowing to unlocking subpage write functionality,
reuqired for Meraki MR18.

Fixes: 6561ca1fa51 ("ath79: ar934x: fix mounting issues if subpage is not supported")
Signed-off-by: Lech Perczak <lech.perczak@gmail.com>
18 months agoapm821xx: rename MerakiNAND -> meraki-header
Christian Lamparter [Sat, 13 May 2023 19:09:56 +0000 (21:09 +0200)]
apm821xx: rename MerakiNAND -> meraki-header

specify that this functions adds a Cisco Meraki
special-sauce header for their custom loader/uboot.

Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
18 months agokernel: bump 5.15 to 5.15.111
John Audia [Fri, 12 May 2023 16:33:18 +0000 (12:33 -0400)]
kernel: bump 5.15 to 5.15.111

Removed upstreamed:
01. backport-5.15/424-v6.4-0001-mtd-core-provide-unique-name-for-nvmem-device-take-t.patch
02. backport-5.15/424-v6.4-0002-mtd-core-fix-nvmem-error-reporting.patch
03. generic-backport/424-v6.4-0003-mtd-core-fix-error-path-for-nvmem-provider.patch
04. generic-backport/828-v6.4-0001-of-Fix-modalias-string-generation.patch
05. bcm4908/patches-5.15/031-v5.17-0002-arm64-dts-broadcom-bcm4908-add-DT-for-Netgear-RAXE50.patch
06. bcm4908/patches-5.15/033-v6.0-0001-arm64-dts-Add-DTS-files-for-bcmbca-SoC-BCM63158.patchgit
07. bcm4908/patches-5.15/033-v6.0-0002-arm64-dts-Add-DTS-files-for-bcmbca-SoC-BCM4912.patchgita
08. bcm4908/patches-5.15/033-v6.0-0010-arm64-dts-Add-base-DTS-file-for-bcmbca-device-Asus-G.patchgit
09. bcm4908/patches-5.15/034-v6.1-0005-arm64-dts-Move-BCM4908-dts-to-bcmbca-folder.patch
10. bcm4908/patches-5.15/036-v6.4-0002-arm64-dts-broadcom-bcmbca-bcm4908-fix-NAND-interrupt.patch
11. bcm4908/patches-5.15/036-v6.4-0004-arm64-dts-broadcom-bcmbca-bcm4908-fix-procmon-nodena.patch
12. ipq806x/patches-5.15/104-v6.0-06-ARM-dts-qcom-ipq8064-reduce-pci-IO-size-to-64K.patch

Manually rebased:
bcm27xx/patches-5.15/950-0078-BCM2708-Add-core-Device-Tree-support.patch
bcm27xx/patches-5.15/950-0547-ARM-dts-Add-Pi-Zero-2-support.patch
bcm4908/patches-5.15/033-v6.0-0001-arm64-dts-Add-DTS-files-for-bcmbca-SoC-BCM63158.patchgit
bcm4908/patches-5.15/033-v6.0-0002-arm64-dts-Add-DTS-files-for-bcmbca-SoC-BCM4912.patchgit
bcm4908/patches-5.15/030-v5.16-0001-arm64-dts-broadcom-bcm4908-Fix-NAND-node-name.patch
bcm4908/patches-5.15/032-v5.18-0002-arm64-dts-broadcom-bcm4908-add-pinctrl-binding.patch
bcm4908/patches-5.15/032-v5.18-0003-arm64-dts-broadcom-bcm4908-add-watchdog-block.patch
bcm4908/patches-5.15/032-v5.18-0004-arm64-dts-broadcom-bcm4908-add-I2C-block.patch
bcm4908/patches-5.15/033-v6.0-0003-ARM64-dts-Add-DTS-files-for-bcmbca-SoC-BCM6858.patchgit
bcm4908/patches-5.15/033-v6.0-0008-arm64-dts-broadcom-bcm4908-Fix-timer-node-for-BCM490.patchgit
bcm4908/patches-5.15/034-v6.1-0001-arm64-dts-broadcom-bcm4908-add-remaining-LED-pins.patch
bcm4908/patches-5.15/034-v6.1-0002-arm64-dts-broadcom-bcm4908-add-LEDs-controller-block.patch
bcm4908/patches-5.15/034-v6.1-0003-arm64-dts-broadcom-bcm4908-add-Asus-GT-AC5300-LEDs.patch
bcm4908/patches-5.15/034-v6.1-0004-arm64-dts-bcmbca-update-BCM4908-board-dts-files.patch

All other patches automatically rebased.

Build system: x86_64
Build-tested: bcm2711/RPi4B, ramips/tplink_archer-a6-v3, filogic/xiaomi_redmi-router-ax6000-ubootmod
Run-tested: bcm2711/RPi4B, ramips/tplink_archer-a6-v3, filogic/xiaomi_redmi-router-ax6000-ubootmod

01. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.111&id=77112d23a671697f0f70695ab901f807e15d2093
02. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.111&id=fe07b3b5af01f42b291f5da0da09d047f50b33a6
03. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.111&id=273be36e420924237f6c9d43cdad96718c13dd52
04. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.111&id=fe8ab85ed4958e58e991bba0aa0a655b552b0273
05. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.111&id=6ae67829fa5e9e71f458f69db42f0e216225616a
06. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.111&id=1994284cb9226b65ca3a6744ce3320218b584f26
07. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.111&id=a46878476c5549a4fde15a31922ce80a50b23492
08. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.111&id=112ff0f2530549d50510f116474924f9c4fad590
09. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.111&id=7c253e98685e6d884d12e2618ef4d2ad90b4fbd7
10. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.111&id=8444b46e163aa9559a0af0381a1d230ec4146eb2
11. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.111&id=6d1af517817a760d7af3dee0fc4603645485495c
12. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.111&id=cc4f0e168a5630ad0491ac5328f1a89f3cf3d04e

Signed-off-by: John Audia <therealgraysky@proton.me>