Compare commits

...

168 Commits
owrt ... main

Author SHA1 Message Date
xx-vv
de4f2b6dcf
Add files via upload 2025-04-17 21:04:08 +08:00
xx-vv
51c648be9e
Update and rename 999-add-tdtech-usb-devices.patch to 898-nradio-usb-add-modem-tdch-mt5710.patch 2025-04-17 21:03:31 +08:00
xx-vv
cc3ca5a2ac
Create 999-add-tdtech-usb-devices.patch 2025-04-17 00:30:01 +08:00
VIKING
daef24bd32 refresh patches 2025-04-16 17:48:55 +08:00
VIKING
7f2aef217e Merge remote-tracking branch 'upstream/master' 2025-04-16 14:26:25 +08:00
Tianling Shen
c25b909304
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-04-16 11:53:43 +08:00
Christian Marangi
71446d8052
generic: fix broken ARM gc sections patch
Upstream version of ARM gc sections skip eeping some section. It was
reported some kernel load hang hence restore what we original did and
introduce a new patch that add the additional entry on top of the
upstream version.

Fixes: #18500
Fixes: 7843f21c5120 ("generic: replace ARM gc sections patch with upstream version")
Tested-by: Stefan Kalscheuer <stefan@stklcode.de> (Turris Omnia)
Link: https://github.com/openwrt/openwrt/pull/18503
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-16 00:43:34 +02:00
Christian Marangi
87cb0446b7
generic: fix broken TCP fraglist GRO patch
Some regression were reported with the backported upstream version. Old
kernel require an additional flush in some case and this was handled in
the old downstream patch.

Reintroduce the flush to fix the regression and refresh affected patch.

Fixes: f63d64ede06b ("generic: move patch from pending to backport")
Link: https://github.com/openwrt/openwrt/pull/18501
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-15 23:26:50 +02:00
Christian Marangi
f98ee3bbab
generic: drop redundant ATS SFP GT-T quirk patch
The ATS SFP GT-T quirk patch was backported to stable kernel 6.6 but
was not notice while bumping the kernel version as they listed the quirk
at the bottom of the SFP quirk table while our hack patch put it at the
top.

With migrating to the upstream version, the duplication was made more
apparent.

Drop the double entry for the SFP module as it's already there and not
needed and refresh patches.

Link: https://github.com/openwrt/openwrt/pull/18484
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-15 23:24:30 +02:00
Robert Marko
e17cbd0488 ipq-wifi: update to Git HEAD (2025-04-15)
953ce37a3191 ipq40xx: Add TP-Link Deco M5 BDF
f818835c7633 ipq5018: add BDF for GL.iNET GL-B3000 Add IPQ5018 BDF for GL.iNET GL-B3000.
38a18dc26c9b qcn6122: add BDF for GL.iNET GL-B3000 Add QCN6122 BDF for GL.iNET GL-B3000.

Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-15 13:50:33 +02:00
Tianling Shen
55f9aa693a
rockchip: add phy leds setup script
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-04-15 16:31:45 +08:00
Tianling Shen
fd2b54a16b
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-04-15 13:40:15 +08:00
Tianling Shen
d36e763056
rockchip: change to use upstream driver for rtl8111
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-04-15 13:34:21 +08:00
VIKINGYFY
736b40c78b Update QCA Source 2025-04-14 23:27:17 +08:00
VIKING
f65d233762 refresh patches 2025-04-14 22:32:19 +08:00
VIKING
f19e28248b Merge remote-tracking branch 'upstream/master' 2025-04-14 22:12:34 +08:00
Tianling Shen
57c24aaa31
r8152: remove unnecessary dependency
It does not depend on kmod-usb-net.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-04-14 17:39:28 +08:00
Tianling Shen
637cb5d990
r8127: enable rss support by default
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-04-14 17:30:35 +08:00
Chukun Pan
e086bb951c kernel: add missing submenu for diag modules
The submenu of two diag modules is missing, fix it.

Fixes: 65de1e0 ("kernel: add missing symbols for lxc")
Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
Link: https://github.com/openwrt/openwrt/pull/18480
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-14 11:01:25 +02:00
Christian Marangi
bed637d9d3
armsr: drop GC sections ARMv7 patch
Drop GC sections ARMv7 patch as the new upstream version already handle
it by disabling the config in the specific EFI boot stub driver.

Link: https://github.com/openwrt/openwrt/pull/18464
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-14 10:28:50 +02:00
Christian Marangi
7843f21c51
generic: replace ARM gc sections patch with upstream version
Replace ARM gc sections patch with upstream version. It seems this
feature is finally supported upstream with some minor difference.

In theory the upstream version should cut even more stuff, this really
needs to be evaluated if it's OK also to handle regression with the
kernel 6.12 update.

Link: https://github.com/openwrt/openwrt/pull/18464
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-14 10:28:49 +02:00
Christian Marangi
ff802ccc44
generic: replace SFP ignore TX FAULT with upstream version
Replace SFP ignore TX FAULT with upstream version by backporting the 2
related upstream patch. Refresh SFP affected patch.

Link: https://github.com/openwrt/openwrt/pull/18464
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-14 10:28:49 +02:00
Christian Marangi
f63d64ede0
generic: move patch from pending to backport
Move all patch that got merged upstream from pending to backport and add
related tag. This is to make it easier to update to kernel 6.12.

Patch 680 required some special care as the upstream version had to be
split in a series of 6 patch.

Referesh all affected patch.

Link: https://github.com/openwrt/openwrt/pull/18464
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-14 10:28:48 +02:00
Tianling Shen
bec5211deb
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-04-14 14:41:22 +08:00
Rudy Andram
b0d43be2f3 dnsmasq: bump release to 2.91
updated 200-ubus_dns.patch
all remaining patches not required

Changelog for version 2.91 - https://thekelleys.org.uk/dnsmasq/CHANGELOG

version 2.91
	Fix spurious "resource limit exceeded messages". Thanks to
	Dominik Derigs for the bug report.

	Fix out-of-bounds heap read in order_qsort().
	We only need to order two server records on the ->serial field.
	Literal address records are smaller and don't have
	this field and don't need to be ordered on it.
	To actually provoke this bug seems to need the same server-literal
	to be repeated twice, e.g., --address=/a/1.1.1.1 --address-/a/1.1.1.1
	which is clearly rare in the wild, but if it did exist it could
	provoke a SIGSEGV. Thanks to Daniel Rhea for fuzzing this one.

	Fix buffer overflow when configured lease-change script name
	is too long.
	Thanks to Daniel Rhea for finding this one.

	Improve behaviour in the face of non-responsive upstream TCP DNS
	servers. Without shorter timeouts, clients are blocked for too long
	and fail with their own timeouts.

	Set --fast-dns-retries by default when doing DNSSEC. A single
	downstream query can trigger many upstream queries. On an
	unreliable network, there may not be enough downstream retries
	to ensure that all these queries complete.

	Improve behaviour in the face of truncated answers to queries
	for DNSSEC records. Getting these answers by TCP doesn't now
	involve a faked truncated answer to the downstream client to
	force it to move to TCP. This improves performance and robustness
	in the face of broken clients which can't fall back to TCP.

	No longer remove data from truncated upstream answers. If an
	upstream replies with a truncated answer, but the answer has some
	RRs included, return those RRs, rather than returning and
	empty answer.

	Fix handling of EDNS0 UDP packet sizes.
	When talking upstream we always add a pseudo header, and set the
        UDP packet size to --edns-packet-max. Answering queries from
	downstream, we get the answer (either from upstream or local
	data) If local data won't fit the advertised size (or 512 if
	there's not an EDNS0 header) return truncated. If upstream
        returns truncated, do likewise. If upstream is OK, but the
	answer is too big for downstream, truncate the answer.

	Modify the behaviour of --synth-domain for IPv6.
	When deriving a domain name from an IPv6 address, an address
	such as 1234:: would become 1234--.example.com, which is
	not legal in IDNA2008. Stop using the :: compression method,
	so 1234:: becomes
	1234-0000-0000-0000-0000-0000-0000-0000.example.com

	Fix broken dhcp-relay on *BSD. Thanks to Harold for finding
	this problem.

	Add --dhcp-option-pxe config. This acts almost exactly like
	--dhcp-option except that the defined option is only sent when
	replying to PXE clients. More importantly, these options are sent
	in reply PXE clients when dnsmasq in acting in PXE proxy mode. In
	PXE proxy mode, the set of options sent is defined by the PXE standard
	and the normal set of options is not sent. This config allows arbitrary
	options in PXE-proxy replies. A typical use-case is to send option
	175 to iPXE. Thanks to Jason Berry for finding the requirement for
	this.

	Support PXE proxy-DHCP and DHCP-relay at the same time.
        When using PXE proxy-DHCP, dnsmasq supplies PXE information to
        the client, which also talks to another "normal" DHCP server
        for address allocation and similar. The normal DHCP server may
        be on the local network, but it may also be remote, and accessed via
        a DHCP relay. This change allows dnsmasq to act as both a
        PXE proxy-DHCP server AND a DHCP relay for the same network.

	Fix erroneous "DNSSEC validated" state with non-DNSSEC
	upstream servers.  Thanks to Dominik Derigs for the bug report.

	Handle queries with EDNS client subnet fields better. If dnsmasq
	is configured to add an EDNS client subnet to a query, it is careful
	to suppress use of the cache, since a cached answer may not be valid
	for a query with a different client subnet. Extend this behaviour
	to queries which arrive a dnsmasq already carrying an EDNS client
	subnet.

	Handle DS queries to auth zones. When dnsmasq is configured to
	act as an authoritative server and has an authoritative zone
	configured, and receives a query for that zone _as_forwarder_
	it answers the query directly rather than forwarding it. This
	doesn't affect the answer, but it saves dnsmasq forwarding the
	query to the recursor upstream, which then bounces it back to dnsmasq
	in auth mode. The exception should be when the query is for the root
	of zone, for a DS RR. The answer to that has to come from the parent,
	via the recursor, and will typically be a proof-of-non-existence
	since dnsmasq doesn't support signed zones. This patch suppresses
	local answers and forces forwarding to the upstream recursor for such
	queries. It stops breakage when a DNSSEC validating client makes
	queries to dnsmasq acting as forwarder for a zone for which it is
	authoritative.

	Implement "DNS-0x20 encoding", for extra protection against
	reply-spoof attacks. Since DNS queries are case-insensitive,
	it's possible to randomly flip the case of letters in a query
	and still get the correct answer back.
	This adds an extra dimension for a cache-poisoning attacker
	to guess when sending replies in-the-blind since it's expected
	that the legitimate answer will have the same  pattern of upper
	and lower case as the query, so any replies which don't can be
	ignored as malicious. The amount of extra entropy clearly depends
	on the number of a-z and A-Z characters in the query, and this
	implementation puts a hard limit of 32 bits to make resource
	allocation easy. This about doubles entropy over the standard
	random ID and random port combination. This technique can interact
	badly with rare broken DNS servers which don't preserve the case
	of the query in their reply. The first time a reply is returned
	which matches the query in all respects except case, a warning
	will be logged. In this release, 0x020-encoding is default-off
	and must be explicitly enabled with --do-0x20-encoding. In future
	releases it may default on. You can avoid a future release
	changing the behaviour of an installation with --no-x20-encode.

	Fix a long-standing problem when two queries which are identical
	in every repect _except_ case, get combined by dnsmasq. If
	dnsmasq gets eg, two queries for example.com and Example.com
	in quick succession it will get the answer for example.com from
	upstream and send that answer to both requestors. This means that
	the query for Example.com will get an answer for example.com, and
	in the modern DNS, that answer may not be accepted.

Signed-off-by: Rudy Andram <rmandrad@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/18357
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-13 21:29:46 +02:00
Hannu Nyman
c79572210f ca-certificates: Update to 20241223
Update ca-certificates to version 20241223

  * Update Mozilla certificate authority bundle to version 2.70.
    The following certificate authorities were added (+):
    + Telekom Security TLS ECC Root 2020
    + Telekom Security TLS RSA Root 2023
    + FIRMAPROFESIONAL CA ROOT-A WEB
    + TWCA CYBER Root CA
    + SecureSign Root CA12
    + SecureSign Root CA14
    + SecureSign Root CA15
    The following certificate authorities were removed (-):
    - Security Communication Root CA (closes: #1063093)

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
Link: https://github.com/openwrt/openwrt/pull/18468
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-13 18:37:16 +02:00
INAGAKI Hiroshi
10a674d277 ath79: fix initramfs execution for NEC Aterm devices
Fix execution of initramfs image on NEC Aterm devices by increasing
available memory for lzma extraction of lzma-loader.

The size of initramfs image of v24.10.0 exceeds available memory
(LZMA_TEXT_START - LOADADDR) and loader data running at LZMA_TEXT_START
will be overwritten by extracted data. As a result, LZMA extraction will
be broken and stuck (or unexpectedly reset).
Fix that issue by setting higher LZMA_TEXT_START address to increase
available memory for LZMA extraction by lzma-loader.

log (v24.10.0):

boot> tftpd
tftpd start 192.168.0.1
boot> start tftp load openwrt-24.10.0-ath79-generic-ne
end tftp load length = 6569768
start memory load ...
memory load complete
  begin  : 0x80040000
  length : 6567044
  startup: 0x80040000

boot> boot
begin  : 0x80040000
length : 6567044
startup: 0x80040000
option: 0x0
NEC Aterm series (QCA9558)

Calibrating SGMII
SGMII cal value = 0xe

Configuring SGMII force mode
  SGMII_CONFIG : 0x000000a2
  MR_AN_CONTROL: 0x00008140
  MR_AN_CONTROL: 0x00000140

OpenWrt kernel loader for AR7XXX/AR9XXX
Copyright (C) 2011 Gabor Juhos <juhosg@openwrt.org>
Decompressing kernel... [:<syntax:value>]');retu  <--- (stuck)
IPL:SOFT-RESET                    <--- (reset by WDT)
memory test ... ok
flinstall OK

boot version: 1.0.0
...

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/18476
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-13 16:54:48 +02:00
Zoltan HERPAI
143569c2ed include: move generic riscv64 ISA to rv64gc
The current CFLAGS (rv64imafdc) for the riscv64 targets do not contain
the full generic compute extension (g), as that also includes the
zicsr and zifencei extensions/instructions. Rename the default ISA to
'generic' to add distinction to the current binaries (although it's very
minimal), and use rv64gc for CFLAGS.

This is also a prep step for the upcoming gcv (vector-extension supporting)
targets like the Spacemit K1, and the thead-cores like the TH1520.

Compile-tested: all riscv64 targets
Runtime-tested:
 - SiFive Unleashed (FU540)
 - SiFive Unmatched (FU740)
 - Nezha D1 (D1)
 - VisionFive2 (JH7110)

Link: https://github.com/openwrt/openwrt/pull/18094
Tested-by: Chuanhong Guo <gch981213@gmail.com> # siflower target
Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
2025-04-13 16:43:31 +02:00
VIKING
d8597403d2 update ath11k-firmware 2025-04-13 22:02:04 +08:00
Robert Marko
8cb7919a13 layerscape: armv7: drop skipped packages
Now that all packages that relied on the skip mechanism are selected
via BUILD_DEVICES or by defaulting for the subtarget drop them from
individual DEVICE_PACKAGES so that Image Builder works again for armv7.

Fixes: #18411
Link: https://github.com/openwrt/openwrt/pull/18462
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-13 11:25:14 +02:00
Robert Marko
598a0556b7 ls-rcw: select by default for layerscape/armv7
Currently, ls-rcw package is being included in the individual
profile DEVICE_PACKAGES but using the feature that allows skipping their
inclusion in the end image package list if prefixed with a tilde(~) which
was added in:
377b66990b97 ("build: introduce support to declare skip package")

But it not added to Image Builder so currently trying to build layerscape
device images in Image Builder will fail with:
ERROR: '~ls-rcw' is not a valid world dependency, format is name(@tag)([<>~=]version)

So, instead of having to rely on support for skipping package installation
and declaring the ls-rcw package in DEVICE_PACKAGES lets select it when
layerscape/armv7 target is selected.

Fixes: #18411
Link: https://github.com/openwrt/openwrt/pull/18462
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-13 11:25:14 +02:00
Robert Marko
c04eaad12a layerscape: armv8_64b: drop skipped packages
Now that all packages that relied on the skip mechanism are selected
via BUILD_DEVICES or by defaulting for the subtarget drop them from
individual DEVICE_PACKAGES so that Image Builder works again for armv8_64b.

Fixes: #18412
Link: https://github.com/openwrt/openwrt/pull/18462
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-13 11:25:14 +02:00
Robert Marko
8a28ddafe7 ls-ddr-phy: select by default for layerscape/armv8_64b
Currently, ls-ddr-phy package is being included in the individual
profile DEVICE_PACKAGES but using the feature that allows skipping their
inclusion in the end image package list if prefixed with a tilde(~) which
was added in:
377b66990b97 ("build: introduce support to declare skip package")

But it not added to Image Builder so currently trying to build layerscape
device images in Image Builder will fail with:
ERROR: '~ls-ddr-phy' is not a valid world dependency, format is name(@tag)([<>~=]version)

So, instead of having to rely on support for skipping package installation
and declaring the ls-ddr-phy package in DEVICE_PACKAGES lets select it when
layerscape/armv8_64b target is selected.

Fixes: #18412
Link: https://github.com/openwrt/openwrt/pull/18462
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-13 11:25:14 +02:00
Robert Marko
84437eeec0 ls-dpl: select by default for layerscape/armv8_64b
Currently, ls-dpl package is being included in the individual
profile DEVICE_PACKAGES but using the feature that allows skipping their
inclusion in the end image package list if prefixed with a tilde(~) which
was added in:
377b66990b97 ("build: introduce support to declare skip package")

But it not added to Image Builder so currently trying to build layerscape
device images in Image Builder will fail with:
ERROR: '~ls-dpl' is not a valid world dependency, format is name(@tag)([<>~=]version)

So, instead of having to rely on support for skipping package installation
and declaring the ls-dpl package in DEVICE_PACKAGES lets select it when
layerscape/armv8_64b target is selected.

Fixes: #18412
Link: https://github.com/openwrt/openwrt/pull/18462
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-13 11:25:14 +02:00
Robert Marko
2fb3efda0a ls-mc: select by default for layerscape/armv8_64b
Currently, ls-mc package is being included in the individual
profile DEVICE_PACKAGES but using the feature that allows skipping their
inclusion in the end image package list if prefixed with a tilde(~) which
was added in:
377b66990b97 ("build: introduce support to declare skip package")

But it not added to Image Builder so currently trying to build layerscape
device images in Image Builder will fail with:
ERROR: '~ls-mc' is not a valid world dependency, format is name(@tag)([<>~=]version)

So, instead of having to rely on support for skipping package installation
and declaring the ls-mc package in DEVICE_PACKAGES lets select it when
layerscape/armv8_64b target is selected.

Fixes: #18412
Link: https://github.com/openwrt/openwrt/pull/18462
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-13 11:25:14 +02:00
Robert Marko
22f02beaab fman-ucode: select by default for layerscape/armv8_64b
Currently, fman-ucode package is being included in the individual
profile DEVICE_PACKAGES but using the feature that allows skipping their
inclusion in the end image package list if prefixed with a tilde(~) which
was added in:
377b66990b97 ("build: introduce support to declare skip package")

But it not added to Image Builder so currently trying to build layerscape
device images in Image Builder will fail with:
ERROR: '~fman-ucode' is not a valid world dependency, format is name(@tag)([<>~=]version)

So, instead of having to rely on support for skipping package installation
and declaring the fman-ucode package in DEVICE_PACKAGES lets select it when
layerscape/armv8_64b target is selected.

Fixes: #18412
Link: https://github.com/openwrt/openwrt/pull/18462
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-13 11:25:14 +02:00
Robert Marko
03ab770da5 tfa-layerscape: set BUILD_DEVICES
Currently, tfa-layerscape packages are being included in the individual
profile DEVICE_PACKAGES but using the feature that allows skipping their
inclusion in the end image package list if prefixed with a tilde(~) which
was added in:
377b66990b97 ("build: introduce support to declare skip package")

But it not added to Image Builder so currently trying to build layerscape
device images in Image Builder will fail with:
ERROR: '~trusted-firmware-a-ls1012a-frdm' is not a valid world dependency, format is name(@tag)([<>~=]version)

So, instead of having to rely on support for skipping package installation
and declaring the individual TFA packages in DEVICE_PACKAGES we can just
do what other targets do and set BUILD_DEVICES so that TFA packages are
automatically set.

Fixes: #18412
Link: https://github.com/openwrt/openwrt/pull/18462
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-13 11:25:14 +02:00
Robert Marko
4a7de50769 bcm63xx-cfe: install into image staging dir
Currently, bcm63xx-cfe is being installed into kernel build dir, however
that does not work for Image Builder as only certain artifacts from kernel
build dir are included in Image Builder.

So, simply install bcm63xx-cfe into image staging dir so its artifacts can
be used in Image Builder as well.

Fixes: #18408
Fixes: #18409
Link: https://github.com/openwrt/openwrt/pull/18463
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-13 10:44:19 +02:00
FUKAUMI Naoki
6690f551c8 rockchip: Add support for Radxa ROCK 4SE
The Radxa ROCK 4SE[1] is a single board computer using the Rockchip
RK3399-T.

Hardware
--------

- Dual-core Cortex-A72 and quad-core Cortex-A53 CPU
- Mali-T860MP4 GPU
- LPDDR4 4GB RAM
- M.2 M Key slot (PCIe 2.1 x4)
- eMMC connector
- microSD card slot
- Wi-Fi 5 (not supported)
- Gigabit Ethernet with PoE support (additional PoE HAT required)
- USB 3.0 Type-A OTG port
- USB 3.0 Type-A HOST port
- 2x USB 2.0 Type-A HOST ports
- USB Type-C power port (5V only)
- 40 Pin GPIO header

[1] https://radxa.com/products/rock4/4se

Installation
------------
Uncompress the OpenWrt sysupgrade and write it to the micro SD card or
internal eMMC using dd.

Signed-off-by: FUKAUMI Naoki <naoki@radxa.com>
Link: https://github.com/openwrt/openwrt/pull/17554
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-13 00:35:46 +02:00
FUKAUMI Naoki
18925614c0 rockchip: Add support for Radxa ROCK 4C+
The Radxa ROCK 4C+[1] is a single board computer with dual HDMI using
the Rockchip RK3399-T.

Hardware
--------

- Dual-core Cortex-A72 and quad-core Cortex-A53 CPU
- Mali-T860MP4 GPU
- LPDDR4 4GB RAM
- eMMC connector
- microSD card slot
- Wi-Fi 5 (not supported)
- Gigabit Ethernet with PoE support (additional PoE HAT required)
- USB 3.0 Type-A OTG port
- USB 3.0 Type-A HOST port
- 2x USB 2.0 Type-A HOST ports
- USB Type-C power port (5V only)
- 40 Pin GPIO header

[1] https://radxa.com/products/rock4/4cp

Installation
------------
Uncompress the OpenWrt sysupgrade and write it to the micro SD card or
internal eMMC using dd.

Signed-off-by: FUKAUMI Naoki <naoki@radxa.com>
Link: https://github.com/openwrt/openwrt/pull/17554
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-13 00:35:46 +02:00
Schneider Azima
7921e48d43 mediatek: add support for Mercusys MR80X v3
This commit adds support for Mercusys MR80X(EU) v3 router.

Device specification:
 - SoC: Mediatek MT7981b, Cortex-A53, 64-bit
 - RAM: 512MB
 - Flash: SPI NAND GigaDevice GD5F1GQ5UEYIGY (128 MB)
 - Ethernet: 4x 100/1000 Mbps LAN1,LAN2,LAN3 & WAN
 - Wireless: 2.4GHz (802.11 b/g/n/ax)
 - Wireless: 5GHz (802.11 a/n/ac/ax)
 - LEDs: 1 orange and 1 green status LEDs, 4 green gpio-controlled LEDs
   on ethernet ports
 - Buttons: 1 (Reset)
 - Bootloader: Main U-Boot - U-Boot 2022.01-rc4. Additionally, both UBI
   slots contain "seconduboot" (also U-Boot 2022.01-rc4)

Installation (UART):
 - Place OpenWrt initramfs-kernel image on tftp server with IP 192.168.1.2
 - Attach UART, switch on the router and interrupt the boot process by
   pressing 'Ctrl-C'.
 - Set the uboot environment for startup.
   setenv tp_boot_idx 0; setenv bootcmd bootm 0x46000000; saveenv
   If the bootarg is set to boot from ubi1, also change it to ubi0.
 - Load and run OpenWrt initramfs image.
   setenv serverip 192.168.1.2; setenv ipaddr 192.168.1.1; tftpboot initramfs-kernel.bin; bootm
 - Browse IP 192.168.1.1, upload the 'sysupgrade' image and do upgrade.

Recovery:
 - Press Reset button and power on the router.
 - Navigate to U-Boot recovery web server (http://192.168.1.1/) and
   upload the OEM firmware.

Stock layout:
0x000000000000-0x000000200000 : "boot"
0x000000200000-0x000000300000 : "u-boot-env"
0x000000300000-0x000003500000 : "ubi0"
0x000003500000-0x000006700000 : "ubi1"
0x000006700000-0x000006f00000 : "userconfig"
0x000006f00000-0x000007300000 : "tp_data"

ubi0/ubi1 format:
U-Boot at boot checks that all volumes are in place:
+-------------------------------+
| Volume Name: uboot   Vol ID: 0|
| Volume Name: kernel  Vol ID: 1|
| Volume Name: rootfs  Vol ID: 2|
+-------------------------------+

MAC addresses:
+---------+-------------------+-----------+
|         | MAC               | Algorithm |
+---------+-------------------+-----------+
| label   | 94:0C:xx:xx:xx:12 | label     |
| WAN     | 94:0C:xx:xx:xx:13 | label+1   |
| LAN     | 94:0C:xx:xx:xx:12 | label     |
| WLAN 2g | 94:0C:xx:xx:xx:11 | label-1   |
| WLAN 5g | 94:0C:xx:xx:xx:10 | label-2   |
+---------+-------------------+-----------+
label MAC address was found in UBI partition "tp_data", file
"default-mac".

Signed-off-by: Schneider Azima <Schneider-Azima12@protonmail.com>
Link: https://github.com/openwrt/openwrt/pull/18181
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-12 23:50:27 +02:00
John Audia
66b5ed7a4e kernel: bump 6.6 to 6.6.87
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.6.87

Manually rebased:
	generic-hack/781-usb-net-rndis-support-asr.patch

All other patches automatically rebased.

Build system: x86/64
Build-tested: flogic/xiaomi_redmi-router-ax6000-ubootmod, ramips/tplink_archer-a6-v3, x86/64
Run-tested: flogic/xiaomi_redmi-router-ax6000-ubootmod, ramips/tplink_archer-a6-v3, x86/64

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/18457
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-12 23:31:39 +02:00
Mantas Pucka
6bbf4a540d
wifi-scripts: add hotplug handler for slow-to-initialize ath12k radios
Some ath12k radios can take long time to initialize and register a
phy. This can cause netifd to fail to detect them during initial scan.
To address this issue, a hotplug script has been added to retry
configuration once they have registered their phy.

Signed-off-by: Mantas Pucka <mantas@8devices.com>
Link: https://github.com/openwrt/openwrt/pull/18459
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-12 10:38:54 +02:00
Mantas Pucka
de205366a2
linux-firmware: ath12k: package firmware for QCN9274
Package wireless firmware for Qualcomm QCN9274.

Signed-off-by: Mantas Pucka <mantas@8devices.com>
Link: https://github.com/openwrt/openwrt/pull/18459
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-12 10:38:54 +02:00
Mantas Pucka
9e3a2466f6
mac80211: ath12k: add patches for 160MHz support
Add series enabling 160MHz channels on ath12k

Signed-off-by: Mantas Pucka <mantas@8devices.com>
Link: https://github.com/openwrt/openwrt/pull/18459
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-12 10:38:53 +02:00
Mantas Pucka
49e6e1daf4
mac80211: ath12k: fix wideband operation on QCN9274
Add patches to enable QCN9274 radios that support both 5GHz and 6GHz
bands.

Signed-off-by: Mantas Pucka <mantas@8devices.com>
Link: https://github.com/openwrt/openwrt/pull/18459
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-12 10:38:53 +02:00
Mantas Pucka
c1acef2e0c
mac80211: ath12k: support fetching regdb from board-2.bin
In board-2.bin available at linux-firmare regdb is stored with
board-id=255. This change is needed to properly use it.

Signed-off-by: Mantas Pucka <mantas@8devices.com>
Link: https://github.com/openwrt/openwrt/pull/18459
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-12 10:38:52 +02:00
Mantas Pucka
2de5564f7d
qualcommbe: ipq95xx: pcs: fix USXGMII link-up failure
USXGMII link-up may fail due to too short delay after PLL reset.
Increase the delay to fix this.

Signed-off-by: Mantas Pucka <mantas@8devices.com>
Link: https://github.com/openwrt/openwrt/pull/18459
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-12 10:38:52 +02:00
Mantas Pucka
cd1acb9db5
qualcommbe: ipq95xx: pcs: support 2.5G PHY
Fixes to PCS driver to support 2.5G PHY

Signed-off-by: Mantas Pucka <mantas@8devices.com>
Link: https://github.com/openwrt/openwrt/pull/18459
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-12 10:38:51 +02:00
Mantas Pucka
e46bc86df7
qualcommbe: ipq95xx: nsscc: fix port5 clock parent
Fix incorrect port5 clock management

Signed-off-by: Mantas Pucka <mantas@8devices.com>
Link: https://github.com/openwrt/openwrt/pull/18459
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-12 10:38:50 +02:00
Mantas Pucka
baf7be6705
qualcommbe: ipq95xx: add bus clock for NSSCC
Missing bus clock prevent access to NSSCC registers and thus it is
impossible change clock configuration, when ethernet connection speed
changes.

Signed-off-by: Mantas Pucka <mantas@8devices.com>
Link: https://github.com/openwrt/openwrt/pull/18459
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-12 10:38:50 +02:00
Mantas Pucka
7450f993e8
qualcommbe: ipq95xx: fix PCIe operation
Add patches that fix:
 * Wrong MSI interrups for PCIe3
 * Hang during reboot due to stopped clocks

Signed-off-by: Mantas Pucka <mantas@8devices.com>
Link: https://github.com/openwrt/openwrt/pull/18459
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-12 10:38:49 +02:00
Paul Donald
412c850f07 lldpd: enable hardware inventory information (TLV) management
lldpd can send several hardware inventory TLV fields. Extend the init
script to provide these when the existing flag 'lldpmed_no_inventory' is
disabled. Five new methods provide default values for some of them,
taken from /etc/os-release and /etc/board.json.

There is no homogeneous method to determine the hardware serial number,
so it can be provided manually, as can asset ID.

Note: properties >= 32 characters are truncated at send time (by lldpd),
and some (Cisco) equipment displays junk after strings >= 32 characters.
So truncate to 31.

Tested on: 24.10.0 (known compatible with 22 and 23 also)

===
Example
===

The following lldpd config lines:

 configure inventory hardware-revision "v0"
 configure inventory software-revision "r28427-6df0e3d02a"
 configure inventory firmware-revision "OpenWrt 24.10.0"
 configure inventory serial-number "ABCDEF-123456"
 configure inventory manufacturer "glinet"
 configure inventory model "GL.iNet GL-MT6000"
 # 32 characters:
 configure inventory asset "abcdefghijklmnopqrstuvwxyz 12345"

Produce the following TLV (decoded by Wireshark):

Telecommunications Industry Association TR-41 Committee - Inventory - Hardware Revision
    1111 111. .... .... = TLV Type: Organization Specific (127)
    .... ...0 0000 0110 = TLV Length: 6
    Organization Unique Code: 00:12:bb (Telecommunications Industry Association TR-41 Committee)
    Media Subtype: Inventory - Hardware Revision (0x05)
    Hardware Revision: v0
Telecommunications Industry Association TR-41 Committee - Inventory - Firmware Revision
    1111 111. .... .... = TLV Type: Organization Specific (127)
    .... ...0 0001 0011 = TLV Length: 19
    Organization Unique Code: 00:12:bb (Telecommunications Industry Association TR-41 Committee)
    Media Subtype: Inventory - Firmware Revision (0x06)
    Firmware Revision: OpenWrt 24.10.0
Telecommunications Industry Association TR-41 Committee - Inventory - Software Revision
    1111 111. .... .... = TLV Type: Organization Specific (127)
    .... ...0 0001 0101 = TLV Length: 21
    Organization Unique Code: 00:12:bb (Telecommunications Industry Association TR-41 Committee)
    Media Subtype: Inventory - Software Revision (0x07)
    Software Revision: r28427-6df0e3d02a
Telecommunications Industry Association TR-41 Committee - Inventory - Serial Number
    1111 111. .... .... = TLV Type: Organization Specific (127)
    .... ...0 0001 0100 = TLV Length: 20
    Organization Unique Code: 00:12:bb (Telecommunications Industry Association TR-41 Committee)
    Media Subtype: Inventory - Serial Number (0x08)
    Serial Number: ABCDEF-123456
Telecommunications Industry Association TR-41 Committee - Inventory - Manufacturer Name
    1111 111. .... .... = TLV Type: Organization Specific (127)
    .... ...0 0000 1010 = TLV Length: 10
    Organization Unique Code: 00:12:bb (Telecommunications Industry Association TR-41 Committee)
    Media Subtype: Inventory - Manufacturer Name (0x09)
    Manufacturer Name: glinet
Telecommunications Industry Association TR-41 Committee - Inventory - Model Name
    1111 111. .... .... = TLV Type: Organization Specific (127)
    .... ...0 0001 0101 = TLV Length: 21
    Organization Unique Code: 00:12:bb (Telecommunications Industry Association TR-41 Committee)
    Media Subtype: Inventory - Model Name (0x0a)
    Model Name: GL.iNet GL-MT6000
Telecommunications Industry Association TR-41 Committee - Inventory - Asset ID
    1111 111. .... .... = TLV Type: Organization Specific (127)
    .... ...0 0010 0011 = TLV Length: 35
    Organization Unique Code: 00:12:bb (Telecommunications Industry Association TR-41 Committee)
    Media Subtype: Inventory - Asset ID (0x0b)
    Asset ID: abcdefghijklmnopqrstuvwxyz 1234

The Cisco DUT displays:

Hardware Revision: 	v0
Firmware Revision: 	OpenWrt 24.10.0
Software Revision: 	r28427-6df0e3d02a
Serial Number:  ABCDEF-123456
Manufacturer Name: 	glinet
Model Name: 	GL.iNet GL-MT6000
Asset ID: 	abcdefghijklmnopqrstuvwxyz 1234

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/18354
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-11 22:51:06 +02:00
Christian Marangi
b68173500a
ath10k-ct: partially revert removal of 003 patch
Partially revert removal of 003 patch to fix compilation error with
kernel 6.6.

In 6.6 .remove still require int and .remove_new needs to be used.

Fixes: bfb106e8ae73 ("mac80211: backport API change for sta rate control update")
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-11 21:40:31 +02:00
Christian Marangi
473cfb4ff5
generic: fix kernel warning no previous prototype for ...
It seems new kernel version introduced -Wmissing-prototypes. This new
warning reported drivers that define non static function that are used
statically in the driver.

Fix this by declaring making those function actually static if not
defined in any header and not used outside of the single driver.

Co-authored-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/18455
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-11 20:34:24 +02:00
Christian Marangi
0b5650f767
generic: add missing of.h header to ar8327
It seems new kernel linux version reorganized the header include and now
of.h needs to be explicitly included. This should have been done from
when the driver was introduced.

Add the missing of.h header to fix compilation error in later kernel
version.

Co-authored-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/18455
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-11 20:34:24 +02:00
Felix Fietkau
f8ed36f0d7 unetmsg: allow communication between hosts if no service is defined
Simplifies unet setup

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2025-04-11 13:02:31 +02:00
Christian Marangi
f212e8b39f
ubootenv-nvram: convert driver to .remove_new
Convert driver to .remove_new in preparation for kernel 6.12 support.

Link: https://github.com/openwrt/openwrt/pull/18454
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-11 11:21:20 +02:00
Christian Marangi
83286b911e
ltq-ptm: convert driver to .remove_new
Convert driver to .remove_new in preparation for kernel 6.12 support.

Link: https://github.com/openwrt/openwrt/pull/18454
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-11 11:21:20 +02:00
Christian Marangi
0432866d1f
ltq-deu: convert driver to .remove_new
Convert driver to .remove_new in preparation for kernel 6.12 support.

Link: https://github.com/openwrt/openwrt/pull/18454
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-11 11:21:19 +02:00
Christian Marangi
fac3d99732
ltq-atm: convert driver to .remove_new
Convert driver to .remove_new in preparation for kernel 6.12 support.

Link: https://github.com/openwrt/openwrt/pull/18454
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-11 11:21:19 +02:00
Christian Marangi
bd532bd48e
ltq-adsl-mei: convert driver to .remove_new
Convert driver to .remove_new in preparation for kernel 6.12 support.

Link: https://github.com/openwrt/openwrt/pull/18454
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-11 11:21:19 +02:00
Christian Marangi
6651efa4ff
gpio-button-hotplug: convert to .remove_new
Convert package to .remove_new in preparation for kernel 6.12 support.

Link: https://github.com/openwrt/openwrt/pull/18454
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-11 11:21:18 +02:00
Christian Marangi
31139fcdfb
generic: convert driver to .remove_new
Convert driver to .remove_new in preparation for kernel 6.12 support.

Link: https://github.com/openwrt/openwrt/pull/18454
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-11 11:21:18 +02:00
Felix Fietkau
372c2ea656 mt76: update to Git HEAD (2025-04-11)
3e25f2bc33af wifi: mt76: mt7925: introduce MLO capability control
ce3622257026 wifi: mt76: mt7925: fix fails to enter low power mode in suspend state
dfdb8e975718 wifi: mt76: mt7915: fix possible integer overflows in mt7915_muru_stats_show()
29f0ad5a439a wifi: mt76: mt7925: ensure wow pattern command align fw format
5eab65bb5473 wifi: mt76: mt7925: fix country count limitation for CLC
d6a197dbc9a2 wifi: mt76: Add check for devm_kstrdup()
901492c4621a wifi: mt76: mt7925: Remove unnecessary if-check
24062ce4fa0f wifi: mt76: mt7925: Simplify HIF suspend handling to avoid suspend fail
56c0beddbed8 wifi: mt76: mt7921: fix kernel panic due to null pointer dereference
11bacfcce3b9 Revert "wifi: mt76: mt7925: Update mt7925_mcu_uni_[tx,rx]_ba for MLO"
2823c50b1c15 wifi: mt76: mt7925: fix the wrong link_idx when has p2p_device
f54ff3cabab6 wifi: mt76: mt7925: fix the wrong simultaneous cap for MLO
aa7d366ccf40 wifi: mt76: mt7925: adjust rm BSS flow to prevent next connection failure
d25359e8bb83 wifi: mt76: mt7925: integrate *mlo_sta_cmd and *sta_cmd
25a0285d8ee3 wifi: mt76: mt7925: update the power-saving flow
5910f0806c05 wifi: mt76: mt7925: load the appropriate CLC data based on hardware type
454a69cbb718 wifi: mt76: mt7925: add EHT control support based on the CLC data
bdc09b8f2321 wifi: mt76: mt7925: update the channel usage when the regd domain changed
772dcb4b4e61 wifi: mt76: mt7925: remove unused acpi function for clc
b94b025490ef wifi: mt76: mt792x: extend MTCL of APCI to version3 for EHT control
9ff2afce5fef wifi: mt76: mt7925: add MTCL support to enhance the regulatory compliance
f11807364258 wifi: mt76: add mt76_get_power_bound helper function
ffd1cbfc485e wifi: mt76: mt7921: fix returned txpower
687e2fdfbf40 wifi: mt76: mt7925: fix returned txpower
43aaa62fbc55 wifi: mt76: mt7915: cleanup mt7915_get_power_bound
a4be3fc9ed4b wifi: mt76: mt7996: cleanup mt7996_get_power_bound
0ba7a69f8927 wifi: mt76: move napi_enable() from under BH
1b370c689a2f wifi: mt76: mt7921: avoid undesired changes of the preset regulatory domain
e931cecc45de mt76: mt792x: fix unused variable warning
539e7e711a15 Revert "wifi: mt76: mt7925: fix returned txpower"
67c724cc60b1 Revert "wifi: mt76: mt7921: fix returned txpower"
52f51a398e7e wifi: mt76: mt7996: Add change_vif_links stub
b3b61abd733f wifi: mt76: mt7996: Introduce mt7996_sta_link container
915938e83c35 wifi: mt76: mt7996: Add mt7996_sta_link struct in mt7996_vif_link
3e06380a43a4 wifi: mt76: mt7996: Add vif_cfg_changed callback
f419c62e9198 wifi: mt76: mt7996: Add link_info_changed callback
3082c9edbe35 wifi: mt76: mt7996: Add mt7996_sta_state routine
46e20e5d7455 wifi: mt76: mt7996: Rely on mt7996_sta_link in sta_add/sta_remove callbacks
1de180821525 wifi: mt76: mt7996: Add mt7996_mac_sta_change_links callback
2efb26f1fc10 wifi: mt76: mt7996: Support MLO in mt7996_mac_sta_event()
2e249744bc12 wifi: mt76: Check link_conf pointer in mt76_connac_mcu_sta_basic_tlv()
0eee20d3e388 wifi: mt76: mt7996: Update mt7996_mcu_add_sta to MLO support
200ce414fe61 wifi: mt76: mt7996: Rely on mt7996_vif_link in mt7996_mcu_twt_agrt_update signature
d195324131ba wifi: mt76: mt7996: Rely on mt7996_vif/sta_link in twt teardown
7757e7c140f7 wifi: mac80211: call rate_control_rate_update() for link STA
a3b651aeb551 wifi: mt76: mt7996: Update mt7996_mcu_add_rate_ctrl to MLO
2a005953dc49 wifi: mt76: mt7996: Add mt7996_mcu_sta_mld_setup_tlv() and mt7996_mcu_sta_eht_mld_tlv()
58e8b71782fc wifi: mt76: mt7996: Add mt7996_mcu_teardown_mld_sta rouine
e0b422f2acaf wifi: mt76: mt7996: rework mt7996_mac_write_txwi() for MLO support
21aa0c288470 wifi: mt76: mt7996: Rely on wcid_to_sta in mt7996_mac_add_txs_skb()
87c437fa8b43 wifi: mt76: mt7996: rework mt7996_rx_get_wcid to support MLO
9b4de3ce7fc7 wifi: mt76: mt7996: rework mt7996_sta_set_4addr and mt7996_sta_set_decap_offload to support MLO
a369b0c14d25 wifi: mt76: mt7996: Add mt7996_sta_link to mt7996_mcu_add_bss_info signature
9c6ec015afbb wifi: mt76: mt7996: rework mt7996_set_hw_key to support MLO
60967d28a5e0 wifi: mt76: mt7996: rework mt7996_sta_hw_queue_read to support MLO
3668d57795e3 wifi: mt76: mt7996: remove mt7996_mac_enable_rtscts()
275e6a681bac wifi: mt76: mt7996: rework mt7996_mac_sta_rc_work to support MLO
057822770ca5 wifi: mt76: mt7996: rework mt7996_mac_sta_poll to support MLO
b9682a51c109 wifi: mt76: mt7996: rework mt7996_update_mu_group to support MLO
d1a5a0afa6d6 wifi: mt76: mt7996: rework mt7996_net_fill_forward_path to support MLO
56529041b364 wifi: mt76: mt7996: rework mt7996_mcu_add_obss_spr to support MLO
c788d5748dc8 wifi: mt76: mt7996: rework mt7996_mcu_beacon_inband_discov to support MLO
974e6c2df98b wifi: mt76: mt7996: set vif default link_id adding/removing vif links
70717b761af2 wifi: mt76: mt7996: rework set/get_tsf callabcks to support MLO
d01b9d300eaa wifi: mt76: mt7996: rework mt7996_ampdu_action to support MLO
d5cddf65f7a7 wifi: mt76: mt7996: Update mt7996_tx to MLO support
a1ed21a66913 wifi: mt76: mt792x: re-register CHANCTX_STA_CSA only for the mt7921 series
a826fc287483 wifi: mt76: mt7925: update MLO cleanup flow during disconnection
0994f0af632e wifi: mt76: mt7925: fix the incomplete revert of [tx,rx]_ba for MLO
5169d4e8669b wifi: mt76: mt76x2u: add TP-Link TL-WDN6200 ID to device table
46f3a10a9f0f mt76: mt7925: sync with upstream cleanups
de635e1e3adc wifi: mt76: mt7996: fix locking in mt7996_mac_sta_rc_work()
63a4edf1cb74 wifi: mt76: mt7996: add macros for pci decive id
a2dd2f7896f7 wifi: mt76: connac: add support to load firmware for mt7990
3908cf04aa39 wifi: mt76: mt7996: rework WA mcu command for mt7990
6243414a4e80 wifi: mt76: mt7996: rework DMA configuration for mt7990
a8def214d736 wifi: mt76: mt7996: rework register mapping for mt7990
51db7a2d57f6 wifi: mt76: mt7996: add eeprom support for mt7990
d0799f3303e9 wifi: mt76: mt7996: adjust HW capabilities for mt7990
10c3ea97a86d wifi: mt76: connac: rework TX descriptor and TX free for mt7990
bc588ac3d104 wifi: mt76: mt7996: rework background radar check for mt7990
f8c3dd3677dd wifi: mt76: mt7996: add PCI device id for mt7990
3cec186474c4 wifi: mt76: mt7915: set correct background radar capability
9bacdb2bf2c3 wifi: mt76: mt7915: rework radar HWRDD idx
a19543c7e05e wifi: mt76: mt7996: rework radar HWRDD idx
b0cf33e76a3a wifi: mt76: mt7925: Fix logical vs bitwise typo
0433adc883c9 wifi: mt76: mt7925: add EHT preamble puncturing
be28ef77e330 wifi: mt76: mt7996: Add NULL check in mt7996_thermal_init

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2025-04-11 11:09:58 +02:00
Felix Fietkau
bfb106e8ae mac80211: backport API change for sta rate control update
Helps stay in sync with mt76 upstream development

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2025-04-11 10:41:12 +02:00
Felix Fietkau
37c80e61ee cli: extend remove call to allow passing values directly
This simplifies script or API usage of this command to remove values directly
without having to calculate the index

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2025-04-11 10:41:12 +02:00
Yang Xiwen
c166cb9661 qualcommax: eap623od-hd-v1: fix phy node and LED config
The reason phy fails to probe without explicitly overrided phy id is
that the reset timing fails to match. Fix it with proper `reset-delay-us` and
`reset-post-delay-us`.

While at it, change LED settings to match EAP610-Outdoor.

Signed-off-by: Yang Xiwen <forbidden405@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/18450
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-11 10:04:35 +02:00
Sergii Shcherbakov
b8eba75146 ramips: mt76x8: add support for MERCUSYS MB130-4G v1
Specification:
SoC: MediaTek MT7628AN
RAM: 128 MB, Zentel A3R1GE40JBF-8E
Flash: 16MB, Winbond W25Q128JV
Switch: rt3050-esw, 2 ports 100 Mbps
WiFi: MediaTek mt7628-wmac 2.4GHz 802.11n and MediaTek MT7663 5GHz
  802.11ac (PCIe)
WWAN: Quectel EC200A-EL 4G modem (USB)
GPIO:
  * 1 button (Reset/WPS)
  * 6 LEDs (Power+WPS, LAN, 3xSignal)
  * USB port power controls
  * Modem reset
  * Modem programming switch
  * Internal/external antenna switch for 4G

Serial Interface:
  TP10 - 3.3V can be used for level shifter, if needed
  TP9 - TX
  TP8 - RX
  TP11 - GND
Interface properties: 115200, 8N1

Access to console using serial port for OEM firmware:
Username: admin
Password: 1234

Flashing via TFTP (no disassembling or soldering required):
1. Connect your PC and router to port LAN
2. Configure PC interface using static IP 192.168.1.225, mask
   255.255.255.0
3. Place OpenWRT firmware image (*-squashfs-tftp-recovery.bin) to TFTP
   root folder and renamed it to tp_recovery.bin
4. Unplug power from router
5. Press and hold Reset/WPS button
6. Power up the router
7. Wait until TFTP started uploading image (~10 seconds after power up)
   and release Reset/WPS button
8. Wait until image uploaded, i.e. until LAN LED start lighting
9. Enable DHCP address on PC interface and wait for assigning address
10. Use ssh (root@192.168.1.1) to configure router properties

Depends on patch for firmware-utils package:
https://github.com/openwrt/firmware-utils/commit/2051fe5b

Signed-off-by: Sergii Shcherbakov <shchers@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17819
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-10 23:12:35 +02:00
Álvaro Fernández Rojas
851ea69d8e package: add kmod-r8127 ethernet driver
r8127 is an out of tree driver provided by Realtek for RTL8127 devices.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2025-04-10 22:39:00 +02:00
Yujie Zhu
db3eff1022 mediatek: filogic: add Netcore N60 Pro support
Hardware specification:
SoC: MediaTek MT7986A 4x A53
Flash: ESMT F50L1G41LB 128MB
RAM: M16U4G16256A DDR4 512MB
Ethernet: 2x 2.5G + 3x 1G
USB: 1x USB 3.0
WiFi1: MT7975N 2.4GHz 4T4R
WiFi2: MT7975PN 5GHz 4T4R
Button: Reset, WPS
Power: DC 12V 2A

Flash instructions:

    Connect to the router using ssh or telnet,
    username: useradmin, password is the web
    login password of the router.
    Use scp to upload bl31-uboot.fip and flash:
    "mtd write xxx-bl31-uboot.fip FIP"
    "mtd erase ubi"
    Connect to the router via the Lan port,
    set a static ip of your PC.
    (ip 192.168.1.254, gateway 192.168.1.1)
    Download initramfs image, reboot router,
    waiting for tftp recovery to complete.
    After openwrt boots up, perform sysupgrade.

Note:

    Back up all mtd partitions before flashing.

Signed-off-by: Yujie Zhu <libriunc@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/18138
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-10 22:19:33 +02:00
VIKINGYFY
62cab9f3fb Update QCA Source 2025-04-10 22:39:23 +08:00
Christian Marangi
779f730914
qualcommbe: disable CONFIG_QCOM_IPA kernel config
CONFIG_QCOM_IPA kernel cofig was enabled by mistake and conflicts with
mac80211 as it indirectly selects QMI HELPERS. Backports project provid
his own version of QMI HELPERS hence it should not be built-in.

Link: https://github.com/openwrt/openwrt/pull/17788
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-10 15:01:12 +02:00
Christian Marangi
692459dd4e
qualcommbe: ipq95xx: Make RPM partition read-only
Make the RPM partition read-only. This was a mistake and a leftover from
staging branch but I can take this mistake as an excuse to document the
current problem with RPM.

It might happen that a board ship with a broken RPM .mbn, broken not in
the sense that the board doesn't boot or it's a brick but broken in the
sense that it's outdaed and suffer from a bug fixed in new version.

This bug consist in a problem with the regulators between USB and NSS.
The old RPM mess with the NSS regulator (l2) and change the voltage for
it while configuring the USB regulator (l5).
This cause the ethernet subsystem to malfunction with the port not
working.

To workaround this, it's needed to disable RPM handling and CPUFreq.
With these 2 disabled, the old RPM doesn't touch regulators and Ethernet
works correctly.

New RPM correctly handle regulators for USB (l5) and doesn't suffer from
this problem. A solution for this is getting discussed with QCOM hoping
to get some good feedback for it.

Link: https://github.com/openwrt/openwrt/pull/17788
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-10 15:01:12 +02:00
Christian Marangi
9c6180e5f1
qualcommbe: ipq95xx: Add pending patch fixing NSSCC boot stall
Add pending patch fixing NSSCC boot stall. These patch are needed to
prevent the ICC to disable critical clock for NSSCC NOC.

Without these the system will stall and reboot with watchdog.

While at it also remove an extra clock from DTSI as it currently have no
use. Original patch is not modified to keep consistency with series
proposed upstream.

Link: https://github.com/openwrt/openwrt/pull/17788
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-10 15:01:11 +02:00
Christian Marangi
1d88859cd3
qualcommbe: ipq95xx: Drop redundant comment in NSSCC clock patch
Drop redundant comment in NSSCC clock patch. The problem has been
identified hence the comment doesn't apply anymore.

Link: https://github.com/openwrt/openwrt/pull/17788
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-10 15:01:11 +02:00
Christian Marangi
0a9dc5a6f4
qualcommbe: ipq95xx: Define default partition table for RFB SPI-NAND
Define default partition table for SPI-NAND mounted on reference board.
This is where is normally placed the rootfs UBI.

Link: https://github.com/openwrt/openwrt/pull/17788
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-10 15:01:11 +02:00
Christian Marangi
7fb8b48120
qualcommbe: ipq95xx: Refresh dts SPI-NAND patch to v14
Refresh dts SPI-NAND patch to to v14. This is to keep stuff synced with
current pending patch revision and make it easier to replace patch
later (and discover something broke in the meantime)

Link: https://github.com/openwrt/openwrt/pull/17788
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-10 15:01:10 +02:00
Christian Marangi
46fcb0056e
qualcommbe: ipq95xx: Refresh the NSSCC and PORT patch for new PCIe patches
Refresh the NSSCC patch for new PCIe patches. To keep track of fuzz
changes for the IPQ95xx patches, patch are not refreshed currently.

For the specific case of NSSCC patch, quilt gets confused and apply the
patch in the wrong node, putting it in the RPM node (causing all kind of
funny errors at runtime)

Correctly fix the patch to put the node right after the PCIe nodes.

Also the PORT patch need to be refreshed as the gpio header is added by
the PCIe patch.

Link: https://github.com/openwrt/openwrt/pull/17788
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-10 15:01:10 +02:00
Christian Marangi
8d081f48a6
qualcommbe: ipq95xx: Add PCIe upstream patch and related nodes
Add PCIe upstream patch and related nodes to enable PCIe on IPQ95xx.

Minimal change were required to backport the patch and apply on current
kernel. Refresh all affected patch.

Link: https://github.com/openwrt/openwrt/pull/17788
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-10 15:01:10 +02:00
Christian Marangi
e272eb4dbf
qualcommbe: ipq95xx: Add USB3 kmods and drop NSS-DP unneeded package
Add USB3 kmods to the default package list, USB3 correctly works on
IPQ95xx hence it can be enabled.

While at it drop the NSS-DP as it was added by mistake as the ethrnet
platform is handled differently on this SoC with pending upstream
drivers.

Link: https://github.com/openwrt/openwrt/pull/17788
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-10 15:01:09 +02:00
Christian Marangi
c21aaa7ec6
kernel: usb: add qualcommbe to the supported target of dwc3-qcom
Add qualcommbe to the supported target of dwc3-qcom kernel module. USB3
is correctly supported on IPQ95xx and can be enabled.

Link: https://github.com/openwrt/openwrt/pull/17788
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-10 15:01:09 +02:00
Christian Marangi
80244360ae
generic: move QCOM SPI NAND driver to generic backports
QCOM SPI NAND driver got merged upstream hence we can drop the special
patch from qualcommax and qualcommbe target and move them to the generic
backports directory to reduce patch maintenance.

While at it refresh any affected patch and target and also backport other
minor fixup for the SPI NAND driver merged upstream later.

Link: https://github.com/openwrt/openwrt/pull/17788
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-10 15:01:09 +02:00
Mieczyslaw Nalewaj
f7c0331c50 kernel: bump 6.6 to 6.6.86
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.6.86

Removed upstreamed:
        generic/pending-6.6/155-usbnet-restore-usb%d-name-exception-for-local-mac-addresses.patch[1]

1. https://web.git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.86&id=2beb999f73b48f3cb04d7cb9c4b5400d59f80f89

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/18443
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2025-04-10 13:42:22 +02:00
VIKING
24c38f2585 Merge remote-tracking branch 'upstream/master' 2025-04-10 18:09:36 +08:00
Álvaro Fernández Rojas
4618d09587 bcm27xx: pull 6.6 patches from RPi repo
Adds latest 6.6 patches from the Raspberry Pi repository.

These patches were generated from:
https://github.com/raspberrypi/linux/commits/rpi-6.6.y/
With the following command:
git format-patch -N v6.6.85..HEAD
(HEAD -> bba53a117a4a5c29da892962332ff1605990e17a)

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2025-04-10 10:36:23 +02:00
Linus Walleij
719f378bfb gemini: Activate serial USB console on the DNS-313
This brings up a serial console on the USB device port of
the DNS-313 by:

- Activating the usbgadget feature
- Selecting the usbgadget-acm package
- Adding an inittab that opens a console at ttyGS0 which is
  the device side of ttyACMn of a connected host

Link: http://patchwork.ozlabs.org/project/openwrt/patch/20250403-dns313-usb-serial-v2-4-d84de8e86931@linaro.org/
Cc: Chuanhong Guo <gch981213@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2025-04-10 09:38:18 +02:00
Linus Walleij
cb650214ba package: usbgadget: Fix subpackage dependencies
Currently if a target wants to use acm or ncm gadget config,
they need to select both usbgadget and the config package
such as usbgadget-acm.

It's better if the target just select usbgadget-acm and get
all dependencies satisfied.

Adding a dependency using +usbgadget fixes this.

Link: http://patchwork.ozlabs.org/project/openwrt/patch/20250403-dns313-usb-serial-v2-3-d84de8e86931@linaro.org/
Reviewed-by: Chuanhong Guo <gch981213@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2025-04-10 09:37:34 +02:00
Linus Walleij
a57bce987a package: usbgadget: Define conffile
The /etc/config/usbgadget file is a conffile, so specify
it as such.

Link: http://patchwork.ozlabs.org/project/openwrt/patch/20250403-dns313-usb-serial-v2-2-d84de8e86931@linaro.org/
Reviewed-by: Chuanhong Guo <gch981213@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2025-04-10 09:36:51 +02:00
Linus Walleij
f0de73f912 package: usbgadget: Require kmod-fs-configfs
The usbgadget package tries to mount and use configfs so it
needs to require the kernel module instead of implying it.

There should be a newline at the end of the file as well.

Link: http://patchwork.ozlabs.org/project/openwrt/patch/20250403-dns313-usb-serial-v2-1-d84de8e86931@linaro.org/
Reviewed-by: Chuanhong Guo <gch981213@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2025-04-10 09:36:18 +02:00
Linus Walleij
3edb06546b kernel: modules: Fix RTL8366RB title
The title of the RTL8366RB was wrong, probably a pure
copy/paste bug by me.

Link: http://patchwork.ozlabs.org/project/openwrt/patch/20250402-fix-rtl8366rb-title-v1-1-d3ced57a0e9c@linaro.org/
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2025-04-10 09:33:22 +02:00
Tianling Shen
1609186976
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-04-10 15:22:41 +08:00
Shiji Yang
eec11fbbb6 generic: crypto: fix jitterentropy initialization failed issue
Sync jitterentropy source code with linux-6.12 to solve the
issue of jitterentropy initialization failed:

[ 9.523489] jitterentropy: Initialization failed with host not compliant with requirements: 9
[ 9.661916] kmodloader: 1 module could not be probed
[ 9.662377] kmodloader: - jitterentropy_rng - 0

In linux upstream commit cf27d9475f37 ("crypto: jitter - use
permanent health test storage"), when FIPS crypto is disabled,
the health test results are always explicitly skipped. That means
it will never return error code 9 (health test failed) again.

Fixes: https://github.com/openwrt/openwrt/issues/16684
Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/18399
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-09 22:33:48 +02:00
Rosen Penev
4e18d224c8 mac80211: ath9k: simplify probe with devm
Upstream backport.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17445
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-09 12:43:30 +02:00
Rosen Penev
8534844847 mac80211: fix led-pin usage
ath9k uses a deprecated GPIO API that assumes a starting base of 0. This
is no longer the case and so must be fixed.

Upstream pending patch.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17445
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-09 12:43:30 +02:00
Rosen Penev
0ac79009dd ath79: fix GPIO numbering with ath9k
ath9k base starts at 512. This is a problem as it uses gpio_request_one
to request the GPIO, which is legacy API.

This upstream pending patch needs to also be ported to mac80211.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17445
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-09 12:43:30 +02:00
Rosen Penev
d70f8dea1e mac80211: ath9k: remove gpio buttons support
This is only used by mach files, which are no longer used in OpenWrt.

Allows removing a custon ath9k_platform.h file.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17445
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-09 12:43:30 +02:00
Rosen Penev
baf73daaac mac80211: ath9k: remove platform leds
These only work with and are useful with mach files. Now that those are
gone, this can go too.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17445
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-09 12:43:30 +02:00
Rosen Penev
e78dc2eae4 mac80211: ath9k: clean up gpiochip
Simplify patch with gpiochip_add_data, struct reduction, new GPIO API,
and header cleanup.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17445
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-09 12:43:30 +02:00
Matthias Schiffer
89f1d56a7e build: bpf: fix LLVM tool paths with host toolchain
Do not assume that the various tools like llc can be found under the
same path as clang; instead, look them up through BPF_PATH (while still
preferring ones found next to clang).

This fixes build in common setups with ccache, where clang resolves to a
path like /usr/lib/ccache/bin/clang, but no other tools can be found at
that location.

Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
Link: https://github.com/openwrt/openwrt/pull/18422
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-09 09:52:21 +02:00
Matthias Schiffer
45f0eb106b build: bpf: drop clang-11 lookup
CLANG_MIN_VER is 12, so there is no point in looking for clang-11.

Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
Link: https://github.com/openwrt/openwrt/pull/18422
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-09 09:52:21 +02:00
Yang Xiwen
5dbf93c8c5 ipq60xx: add support for TP-Link EAP623-Outdoor HD v1
Specifications:
* SoC: Qualcomm IPQ6018 (64-bit Quad-core Arm Cortex-A53 @ 1800MHz)
* Memory: 1 GiB
* Serial Port: 3v3 TTL 115200n8
* Wi-Fi: QCN9074 (4x4 5 GHz 802.11ax)
* Wi-Fi: IPQ6018 (4x4 2.4 GHz 802.11b/g/n/ax)
* Ethernet: RTL8211F (10/100/1GBASE-T)
* Flash: ESMT F59D1G81MB (128 MiB)
* LEDs: 1x Green Status (GPIO 37 Active High), 1x Yellow Status (GPIO 32
  Active High) and an LED global control GPIO (GPIO 36 Active High, set
  up by U-Boot)
* Buttons: 1x Reset (GPIO 9 Active Low)

Installation Instructions (Serial+TFTP):
1. Solder 4 pin header to the pads near T32 and T31.
2. Connect 3V3 TTL port to TX, RX, and GND, which are pad T31, T32 and
   the pad near T31 respectively. Be sure not to connect VCC and
   crossover TX and RX.
3. Copy RAM firmware image
   openwrt-qualcommax-ipq60xx-tplink_eap623od-hd-v1-initramfs-uImage.itb
   to TFTP server root, available at 192.168.0.1.
4. Connect PoE ethernet cable to the RJ45 port and hold Ctrl+B in the
   serial console (115200 baud) until autoboot is halted.
5. Run the following commands in the U-boot prompt:
   # setenv serverip 192.168.0.1
   # setenv ipaddr 192.168.0.99
   # tftpboot 0x44000000 openwrt-qualcommax-ipq60xx-tplink_eap623od-hd-v1-initramfs-uImage.itb
   # bootm
   You may need to type Ctrl+C and Enter before running these commands
   to clear invisible characters from the buffer.
6. Run the following command in a terminal to copy the sysupgrade image
   to be installed (check IP address):
   $ scp openwrt-qualcommax-ipq60xx-tplink_eap623od-hd-v1-squashfs-sysupgrade.bin root@192.168.1.1:/tmp/
7. Activate the OpenWrt serial console and run the following commands:
   # cd /tmp
   # sysupgrade -n openwrt-qualcommax-ipq60xx-tplink_eap623od-hd-v1-squashfs-sysupgrade.bin
8. The AP will reboot and OpenWrt will be successfully installed.

Signed-off-by: Yang Xiwen <forbidden405@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/18389
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-09 09:50:31 +02:00
Robert Marko
1cb5297ac3 ipq-wifi: update to Git HEAD (2025-04-08)
5aa50e188feb ipq40xx: add BDF for Alibaba AP4220
7d2a86c01a52 ipq6018: add TP-Link EAP623-Outdoor HD v1 BDF
9591c9b7578a Remove executable permissions

Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-04-08 17:40:06 +02:00
Andrew LaMarche
f44984f19c an7581: fix phy2 led1 function
PHY2 led1 is configured to control PHY1's LED. Change it to PHY2.

Signed-off-by: Andrew LaMarche <andrewjlamarche@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/18361
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-07 23:57:15 +02:00
Matthias Schiffer
af93874f4e
ipq40xx: qca8k: hook up IPQ4019 bridge flag offloading
Adds support for setting bridge port learning and isolation flags on
ipq40xx.

Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
Link: https://github.com/openwrt/openwrt/pull/18375
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-07 23:13:25 +02:00
Matthias Schiffer
5d1dedd9f7
generic: qca8k: backport bridge port isolation support
Bridge port isolation offload support has been added to the bridge core
and many DSA drivers. mt7530 support was backported in OpenWrt commit
c4e6a147a6c0 ("generic: 6.6: mt7530: add support for bridge port
isolation").

Backport qca8k support as well.

Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
Link: https://github.com/openwrt/openwrt/pull/18375
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2025-04-07 23:13:25 +02:00
VIKING
9585373403 Merge remote-tracking branch 'upstream/master' 2025-04-07 22:27:20 +08:00
Tianling Shen
08323e5c28
Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2025-04-07 20:36:05 +08:00
Christian Steiner
d9f30b64ad realtek: add support for D-Link DGS-1210-26
This patch adds support for D-Link DGS-1210-26 rev. F1

Hardware specification
----------------------

* RTL8382M SoC, 1 MIPS 4KEc core @ 500MHz
* 128MB DRAM
* 32MB NOR Flash (MX25L25635E)
* 24 x 10/100/1000BASE-T ports
* 2 x SFP ports
* Power LED
* Reset button on front panel

Installation using OEM webinterface
-----------------------------------

1. Make sure you are running OEM firmware from secondary slot. If not, switch to image2 using the menus
     System > Firmware Information > Boot from image2
     Tools > reboot
2. Upload image squashfs-factory_image1.bin via Tools > Backup / Upgrade Firmware > image1
3. Toggle startup image via System > Firmware Information > Boot from image1
4. Tools > reboot

Known working firmware version for this procedure: 6.20.007

Installation using TFTP and serial console
------------------------------------------

1. Prepare a TFTP server with the OpenWrt *initramfs-kernel.bin and assign it an IP from 10.90.90.0/24 (except 10.90.90.90)
2. Connect the TFTP server to one of switch's ports
3. Connect to the serial console (115200 baud) and power on the switch
4. Press the ESC key once you see "Hit Esc key to stop autoboot" in the console output
5. Press CTRL+C keys to get into the real U-Boot prompt
6. Init the network with the command "rtk network on"
7. Load the OpenWrt image with the command "tftpboot 0x8f000000 <TFTP_SERVER_IP>:<IMAGE_FILE>"
   (<TFTP_SERVER_IP> is the TFTP server's IP, e.g. 10.90.90.100; <IMAGE_FILE> is the name of the image provided by the TFTP server)
8. Boot the OpenWrt image with the command "bootm"
9. Browse to https://192.168.1.1/cgi-bin/luci/admin/system/flash
10. Upload the the OpenWrt *squashfs-sysupgrade.bin to the switch
11. Wait for it to reboot

Signed-off-by: Christian Steiner <christian.steiner@outlook.de>
Link: https://github.com/openwrt/openwrt/pull/18378
Signed-off-by: Sander Vanheule <sander@svanheule.net>
2025-04-07 12:22:00 +02:00
Matthias Franck
84e0900867 busybox: use external libtirpc when using glibc
In recent glibc versions rpc functionality has been moved to a separate
library instead of glibc itself.
Depend on this library when rpc functionality is needed and glibc is
used.

Signed-off-by: Matthias Franck <matthias.franck@softathome.com>
Link: https://github.com/openwrt/openwrt/pull/17796
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-07 01:00:45 +02:00
Ming Kuang
86eb1c0b5a wifi-scripts: mac80211.sh: add EHT and HE160 support to iw_htmode
For WIFI7 devices (such as mt7925e), the dev width is currently
always "20 MHz (no HT)" in monitor mode.

Add EHT and HE160 support to iw_htmode to fix this issue.
Additionally, the following changes are made:
1. Set iw_htmode to 160MHz for VHT160. The reason for the current
   VHT160 setting is unclear and seems to have been in place for
   over a decade (ibss_htmode [1]). If anyone knows its impact,
   please inform me so I can restore it.
2. Modify MHZ to MHz. The original matching table in the current
   iw tool uses MHz. Although the match is case-insensitive,
   correcting this won't hurt.

[1]: 768d09be87

Signed-off-by: Ming Kuang <ming@imkuang.com>
Link: https://github.com/openwrt/openwrt/pull/18319
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-07 00:53:54 +02:00
INAGAKI Hiroshi
f76185c3f3 ath79: add support for NEC Aterm WG2200HP
NEC Aterm WG2200HP is a 2.4/5 GHz band 11ac (Wi-Fi 5) router, based on
QCA9558.

Specification:

- SoC              : Qualcomm Atheros QCA9558
- RAM              : DDR2 128 MiB (2x ESMT M14D5121632A)
- Flash            : SPI-NOR 16 MiB (Macronix MX25L12835FM2I-10G)
- WLAN             : 2.4/5 GHz
  - 2.4 GHz        : 3T3R (Qualcomm Atheros QCA9558 (SoC))
  - 5 GHz          : 4T4R (Qualcomm Atheros QCA9984)
- Ethernet         : 5x 10/100/1000 Mbps
  - switch         : Qualcomm Atheros QCA8337
- LEDs/Keys (GPIO) : 12x/4x
- UART             : through-hole on PCB
  - assignment     : 3.3V, GND, NC, TX, RX from tri-angle marking
  - settings       : 9600n8
- USB              : 1x USB 2.0 Type-A
- Power            : 12 VDC, 1.5 A (Max: 20 W)
- Stock OS         : NetBSD based

Flash instruction using initramfs-factory.bin image:

 1. Connect and open serial console
 2. Power on WG2200HP and interrupt bootloader by ESC key
 3. Login to the bootloader CLI with a password "chiron"
 4. Start TFTP server by "tftpd" command
 5. Upload initramfs-factory.bin via tftp from your computer

    example (Windows): tftp -i 192.168.0.1 PUT initramfs-factory.bin

 6. Boot initramfs image by "boot" command
 7. On the initramfs image, back up the stock bootloader and firmware if
    needed
 8. Upload (or download) uboot.bin and sysupgrade.bin image to the device
 9. Rplace the bootloader with a uboot.bin image

    mtd write <uboot.bin image> bootloader

10. Perform sysupgrade with a sysupgrade.bin image
11. Wait ~120 seconds to complete flashing

Notes:

- All LEDs are connected to the Diodes PI4IOE5V9539LE I2C Expander chip.
  (compatible with NXP PCA9539)

- The stock bootloader requires an unknown filesystem on firmware area
  in the flash. Booting of OpenWrt from that filesystem cannot be
  handled, so the bootloader needs to be replaced to mainline U-Boot
  before OpenWrt installation.

- The data length of blocks in firmware image will be checked
  (4M < threshold < 6M) on the stock WebUI of all versions, and
  initramfs-factory.bin image of OpenWrt has the larger block data for
  initramfs image. So that image cannot be applied to the stock WebUI
  at all.

MAC addresses:

LAN    : 98:F1:99:xx:xx:7C (config, 0x6  (hex))
WAN    : 98:F1:99:xx:xx:7D (config, 0xc  (hex))
2.4 GHz: 98:F1:99:xx:xx:7E (config, 0x0  (hex))
5 GHz  : 98:F1:99:xx:xx:7F (config, 0x12 (hex))

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17584
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-07 00:42:18 +02:00
INAGAKI Hiroshi
76e0338247 ath79: update dtsi/dts for NEC Aterm devices based on QCA9558
Add more DT labels and move a USB hub node to dts files of Aterm devices
as a preparation for adding support of Aterm WG2200HP.

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17584
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-07 00:42:18 +02:00
INAGAKI Hiroshi
367e5c00bd uboot-ath79: build U-Boot/qca9558_nec_aterm for NEC Aterm WG2200HP
Enable building U-Boot/qca9558_nec_aterm profile for NEC Aterm WG2200HP.
This model has almost the same hardware as the other Aterm devices based
on Qualcomm Atheros QCA9558.

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17584
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-07 00:42:18 +02:00
Mikhail Zhilkin
d8002cb627 mediatek: add support for netis NX31
This PR adds support for netis NX31 router.

Specification
-------------
- SoC       : MediaTek MT7981BA dual-core ARM Cortex-A53 1.3 GHz
- RAM       : 256 MiB DDR3
- Flash     : SPI-NAND 128 MiB (ESMT)
- WLAN      : MediaTek MT7976CN dual-band WiFi 6
  - 2.4 GHz : b/g/n/ax, MIMO 2x2
  - 5 GHz   : a/n/ac/ax, MIMO 2x2
- Ethernet  : 10/100/1000 Mbps x3 (LAN, MediaTek MT7531AE)
              10/100/1000 Mbps x1 (WAN, SoC internal phy)
- USB       : No
- Buttons   : Mesh, Reset
- LEDs      : 1x Power (blue), unmanaged
              1x Status (blue), gpio-controlled
              1x WiFi 2.4 GHz (blue), gpio-controlled
              1x WiFi 5 GHz (blue), gpio-controlled
              3x LAN activity (blue), switch-controlled
              1x WAN activity (blue), gpio-controlled
- Power     : 12 VDC, 1 A

Installation
------------
1. Connect to the router using ssh (user: admin, pass: web interface
   password)
2. Make mtd backup:
   cat /dev/mtd0 | gzip -1 -c > /tmp/mtd0_spi0.0.bin.gz
   cat /dev/mtd1 | gzip -1 -c > /tmp/mtd1_BL2.bin.gz
   cat /dev/mtd2 | gzip -1 -c > /tmp/mtd2_u-boot-env.bin.gz
   cat /dev/mtd3 | gzip -1 -c > /tmp/mtd3_Factory.bin.gz
   cat /dev/mtd4 | gzip -1 -c > /tmp/mtd4_FIP.bin.gz
   cat /dev/mtd5 | gzip -1 -c > /tmp/mtd5_ubi.bin.gz
3. Download mtd backup from the /tmp dir of the router to your PC using
   scp protocol
4. Upload OpenWrt 'bl31-uboot.fip', 'preloader.bin' images to the /tmp
   dir of the router using scp protocol
5. Write FIP and BL2 (replace bootloader):
   mtd write /tmp/openwrt-mediatek-filogic-netis_nx31-bl31-uboot.fip FIP
   mtd write /tmp/openwrt-mediatek-filogic-netis_nx31-preloader.bin BL2
6. Place OpenWrt
   'openwrt-mediatek-filogic-netis_nx31-initramfs-recovery.itb' image on
   the tftp server (IP: 192.168.1.254)
7. Erase 'ubi' partition and reboot the router:
   mtd erase ubi
   reboot
8. U-Boot automatically boot OpenWrt recovery image from tftp server to
   the RAM
9. Upload OpenWrt 'sysupgrade.itb' image to the /tmp dir of the router
   (IP: 192.168.1.1) using scp protocol
10. Connect to the router using ssh and run:
    sysupgrade -n openwrt-mediatek-filogic-netis_nx31-squashfs-sysupgrade.itb

Return to stock
---------------
1. Unpack stock BL2 and FIP partitions backup
2. Upload stock BL2 and FIP partitions backup to the /tmp dir of the
   router using scp protocol
3. Connect to the router using ssh and run:
   apk update && apk add kmod-mtd-rw
   insmod mtd-rw i_want_a_brick=1
   mtd unlock BL2
   mtd unlock FIP
4. Restore backup:
   mtd write /tmp/mtd4_FIP.bin FIP
   mtd write /tmp/mtd1_BL2.bin BL2
5. Erase ubi and reboot:
   mtd erase ubi
   reboot
6. Power off the router
7. Press Reset button and power on the router. Release the button after
   ~10 sec
8. Navigate to U-Boot recovery web server (http://192.168.1.1/) and
   upload the OEM firmware

Recovery
--------
1. Place OpenWrt
   'openwrt-mediatek-filogic-netis_nx31-initramfs-recovery.itb' image on
   the tftp server (IP: 192.168.1.254)
2. Press “Reset” button and power on the router. After ~10 sec release
   the button.
3. Use OpenWrt initramfs system for recovery

MAC addresses
-------------
+---------+-------------------+-----------+
|         | MAC               | Algorithm |
+---------+-------------------+-----------+
| LAN     | dc:xx:xx:d1:xx:18 | label     |
| WAN     | dc:xx:xx:d1:xx:1a | label+2   |
| WLAN 2g | de:xx:xx:11:xx:19 |           |
| WLAN 5g | de:xx:xx:71:xx:19 |           |
+---------+-------------------+-----------+
The LAN MAC was found in 'Factory', 0x1fef20
The WAN MAC was found in 'Factory', 0x1fef26
The WLAN 2g/5g MAC prototype was found in 'Factory', 0x4

Signed-off-by: Mikhail Zhilkin <csharper2005@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/18324
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-06 20:14:18 +02:00
George Sapkin
14a88ba520 tools/expat: bump to 2.7.1 to fix several CVEs
Addresses CVE-2024-8176 and CVE-2024-50602.

Changelog: https://github.com/libexpat/libexpat/blob/R_2_7_1/expat/Changes
Fixes: https://github.com/openwrt/packages/issues/26255
Fixes: https://github.com/advisories/GHSA-9hcv-xw76-m4h6
Fixes: https://github.com/advisories/GHSA-79wf-qgrg-2p6c
Signed-off-by: George Sapkin <george@sapk.in>
Link: https://github.com/openwrt/openwrt/pull/18421
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-06 20:01:46 +02:00
Fil Dunsky
99ea96c297 mediatek: filogic: add support for Huasifei WH3000
**Huasifei WH3000 eMMC / Fudy MT3000**
Portable Wi-Fi 6 travel router based on MediaTek MT7981A SoC.
MT7981B+MT7976CN+RTL8221B Dual Core 1.3GHZ

**Specifications**
SoC: Filogic 820 MT7981A (1.3GHz)
RAM: DDR4 1GB
Flash: eMMC 8GB
WiFi: 2.4GHz and 5GHz with 3 antennas
Ethernet:
1x WAN (10/100/1000M)
1x LAN (10/100/1000/2500M)
USB: 1x USB 3.0 port
Two buttons: power/reset and mode (BTN_0)
LEDS: blue, red, blue+red=pink
UART: 3.3V, TX, RX, GND / 115200 8N1

**Installation via U-Boot rescue**
1. Set static IP 192.168.1.2 on your computer and default route as 192.168.1.1
2. Connect to the WAN port and hold the reset button while booting the device.
3. Wait for the LED to blink 5 times, and release the reset button.
4. Open U-boot web page on your browser at http://192.168.1.1
5. Select the OpenWRT sysupgrade image, upload it, and start the upgrade.
6. Wait for the router to flash the new firmware.
7. Wait for the router to reboot itself.

**Installation via sysupgrade**
Just flash sysupgrade file via [LuCI upgrade page](http://192.168.1.1/cgi-bin/luci/admin/system/flash) without saving the settings.

**Installation via SSH**
Upload the file to the router `/tmp` directory, `ssh root@192.168.1.1` and issue a command:
```
sysupgrade -n /tmp/openwrt-mediatek-filogic-huasifei_wh3000-emmc-squashfs-sysupgrade.bin
```

**Factory MAC**
You can find your Factory MAC which is mentioned on the box at `/dev/mmcblck0p2` partition `factory` starting from `0x4`
```
dd if=/dev/mmcblk0p2 bs=1 skip=4 count=6 | hexdump -C
```

**Enlarging a partition**
Though device has 8GB eMMC, it uses only 2GB `/dev/mmcblck0p6` as `rootfs` for `/rom` and `/overlay` leaving `/dev/mmcblck0p7` as empty unused space.
```
sgdisk -p /dev/mmcblk0
```
```
Disk /dev/mmcblk0: 15269888 sectors, 7.3 GiB
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): 2BD17853-102B-4500-AA1A-8A21D4D7984D
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 14942174
Partitions will be aligned on 1024-sector boundaries
Total free space is 11197 sectors (5.5 MiB)

Number  Start (sector)    End (sector)  Size       Code  Name
   1            8192            9215   512.0 KiB   8300  u-boot-env
   2            9216           13311   2.0 MiB     8300  factory
   3           13312           21503   4.0 MiB     8300  fip
   4           21504           29695   4.0 MiB     8300  config
   5           29696           62463   16.0 MiB    8300  kernel
   6           62464         4256767   2.0 GiB     8300  rootfs
   7         4257792        14940159   5.1 GiB     8300
```

You can fix that by loading into `initramfs-kernel`, deleting empty `mmcblck0p7` partition and resizing `mmcblck0p6`
```
sysupgrade -F /tmp/openwrt-initramfs-kernel.bin
```
Install and run cfdisk
```
opkg update && opkg install cfdisk
cfdisk /dev/mmcblck0
```
- Select `mmcblck0p7` -> Delete
- Select `mmcblck0p6` -> Resize -> Write -> yes -> Quit

You will not see any difference in `cat /proc/partitions` after that but just flash a `sysupgrade` and you'll get the whole 7.3GB space for the `/overlay`.

Co-developed-by: hecatae <horus.ra@gmail.com>
Signed-off-by: Fil Dunsky <filipp.dunsky@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/18220
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2025-04-06 19:22:09 +02:00
Stijn Tintel
c891ad99f8 arm-trusted-firmware-rockchip: support rk3588
ATF supports rk3588 since version 2.12, so let's enable it in
arm-trusted-firmware-rockchip.

We still need the TPL to initialize RAM, but keeping rk3588 in rkbin
would cause a duplicate package name, so rename rk3588 to rk3588-tpl in
rkbin.

Finally, point uboot-rockchip for rk3588 to bl31 built by this package,
and add a dependency on the new trusted-firmware-a-rk3588-tpl pacakge.

While this doesn't necessarily add features, we now no longer rely on
the rk3588_bl31_v1.45.elf blob provided by Rockchip, which is always a
good thing.

Tested on Radxa ROCK 5B+.

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
2025-04-06 14:22:19 +03:00
Stijn Tintel
b1a2ebbd43 arm-trusted-firmware-rockchip: bump to 2.12.1 LTS
And remove no-warn-rwx-segments hack, as this is no longer needed and
actually causes build to fail. See also commit c117d7a37a74
("include/trusted-firmware-a.mk: remove the no-warn-rwx-segments hack").

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
2025-04-06 14:22:19 +03:00
Stijn Tintel
06c4e8a262 include/trusted-firmware-a.mk: support LTS releases
TF-A LTS releases have an lts- prefix in their version tag. Introduce a
PKG_LTS variable to support these.

As the non-LTS tarbals do not contain the version prefix in the
directory, we need different PKG_BUILD_DIR for each variant:

➜ tar --list --file dl/trusted-firmware-a-v2.12.tar.gz  | head -n1
trusted-firmware-a-2.12/
➜ tar --list --file dl/trusted-firmware-a-lts-v2.12.1.tar.gz  | head -n1
trusted-firmware-a-lts-v2.12.1/

Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
2025-04-06 14:21:07 +03:00
Stijn Tintel
aedd5b9278 rkbin: drop TFA_MAKE_FLAGS
The rkbin package doesn't compile anything, so TFA_MAKE_FLAGS is unused.

Suggested-by: Tianling Shen <cnsztl@immortalwrt.org>
Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
2025-04-06 12:01:15 +03:00
VIKINGYFY
6eca978401 Update QCA Source 2025-04-05 18:26:42 +08:00
VIKING
bc3ee3d25a Merge remote-tracking branch 'upstream/master' 2025-04-05 18:16:00 +08:00
Russell Senior
9ec997b850 iproute2: update to v6.14.0
$ git log --no-merges --oneline v6.13.0..v6.14.0
fea1086c (tag: v6.14.0) v6.14.0
afbfd2f2 tc: nat: ffs should operation on host byte ordered data
667817b4 tc: nat: Fix mask calculation
e3f9681d ss: mptcp: subflow: display seq counters as decimal
5e113aba man: document tunnel options in ip-route.8.in
48717184 README.devel: clarify patch rules and syntax
99c119a0 ss: Tone down cgroup path resolution
41710ace uapi: update bpf.h
1db4f568 ip: vxlan: Support IFLA_VXLAN_RESERVED_BITS
fe4100df iproute2: add 'ip monitor acaddress' support
d009b68f Update kernel headers
0bd19d46 iprule: Add flow label support
35ae138e ip: route: Add IPv6 flow label support
3f8c7e7c tc: fq: add support for TCA_FQ_OFFLOAD_HORIZON attribute
49b8a727 Update kernel headers
19514606 iproute2: add 'ip monitor maddress' support
93360313 Update kernel headers
1f0f9deb ip: link: rmnet: add support for flag handling

Signed-off-by: Russell Senior <russell@personaltelco.net>
2025-04-05 01:46:47 -07:00
VIKINGYFY
52637c3c2f Update QCA Source 2025-04-04 15:06:21 +08:00
VIKINGYFY
961a5b24ee openssl: update to 3.4.0 2025-04-03 23:12:29 +08:00
VIKING
6d6114d43b Merge remote-tracking branch 'upstream/master' 2025-04-03 22:12:45 +08:00
VIKING
6e46f58d2b Update QCA Source 2025-04-03 22:10:14 +08:00
VIKING
bb855b211b
Merge pull request #73 from ZqinKing/main 2025-04-02 16:46:22 +08:00
ZqinKing
a0977ba4a9 fix mac80211
Signed-off-by: ZqinKing <zqinking23@gmail.com>
2025-04-02 08:36:24 +00:00
VIKING
962c717e2a refresh patches 2025-04-02 09:52:11 +08:00
VIKING
0503190ffa Merge remote-tracking branch 'upstream/master' 2025-04-02 09:39:54 +08:00
VIKINGYFY
64b75379b9 Update QCA Source 2025-04-01 22:29:07 +08:00
VIKING
f2debfb5f1 refresh patches 2025-04-01 00:07:52 +08:00
VIKING
5b60c11e57 Merge remote-tracking branch 'upstream/master' 2025-03-30 20:46:50 +08:00
VIKING
84357d1dc4 Update QCA Source 2025-03-30 20:46:24 +08:00
VIKING
44f803efa8 Merge remote-tracking branch 'upstream/master' 2025-03-30 09:51:30 +08:00
VIKING
bf00eabe3d Update QCA Source 2025-03-29 21:50:24 +08:00
VIKING
d392156a7c Merge remote-tracking branch 'upstream/master' 2025-03-28 22:21:59 +08:00
VIKING
8fcd5d09e3 Merge remote-tracking branch 'upstream/master' 2025-03-28 22:14:49 +08:00
VIKING
4c4dda4591 Update QCA Source 2025-03-28 00:55:22 +08:00
VIKING
6a288466d9 Merge remote-tracking branch 'upstream/master' 2025-03-25 23:37:33 +08:00
VIKING
86f60c475a Update QCA Source 2025-03-25 20:10:54 +08:00
VIKING
c78b8a7ef3 Merge remote-tracking branch 'upstream/master' 2025-03-25 16:24:14 +08:00
VIKING
171047b353 Merge remote-tracking branch 'upstream/master' 2025-03-24 08:26:07 +08:00
VIKING
fb38fa6793 Update QCA Source 2025-03-24 08:16:40 +08:00
VIKING
01d9857d50 Merge remote-tracking branch 'upstream/master' 2025-03-21 22:45:32 +08:00
VIKING
a85e96c81a Merge remote-tracking branch 'upstream/master' 2025-03-20 15:02:52 +08:00
VIKING
eb1eb35c4f Merge remote-tracking branch 'upstream/master' 2025-03-18 21:47:51 +08:00
VIKING
5d53493f9c refresh patches 2025-03-15 22:05:48 +08:00
VIKING
4b4bfa2906 Merge remote-tracking branch 'upstream/master' 2025-03-15 21:25:14 +08:00
VIKING
3088a5601c Merge remote-tracking branch 'upstream/master' 2025-03-15 21:17:43 +08:00
VIKING
29a6ff527d Merge remote-tracking branch 'upstream/master' 2025-03-10 17:17:17 +08:00
VIKING
a2cf419c64 Update QCA Source 2025-03-10 17:12:28 +08:00
VIKING
0daba95cf6 Merge remote-tracking branch 'upstream/master' 2025-03-09 20:50:12 +08:00
VIKING
20bf6eb371
Merge pull request #69 from breeze303/main
qualcommax: fix ipq5018 jdc_re-cs-03 (test)
2025-03-09 16:08:51 +08:00
breeze303
ca09e54dda qualcommax: fix ipq5018 jdc_re-cs-03 (test)
详情:
1.修复了dts导致的无法启动问题
2.修复了网口错乱问题(WAN口暂无测试)
3.无线部分暂未修复

Signed-off-by: breeze303 <grapenskrskr@gmail.com>
2025-03-08 10:01:27 +08:00
VIKING
c3722b051e Update QCA DTS 2025-03-05 23:13:44 +08:00
VIKING
52dc637e07 refresh patches 2025-03-05 23:13:44 +08:00
VIKING
7bd7bd1c3a Merge remote-tracking branch 'upstream/master' 2025-03-04 22:49:07 +08:00
VIKING
1206559fc2 refresh patches 2025-03-04 10:20:07 +08:00
VIKING
9fdaaeb965 Merge remote-tracking branch 'upstream/master' 2025-03-02 21:43:21 +08:00
VIKING
4918e13133 Merge remote-tracking branch 'upstream/master' 2025-03-01 17:19:54 +08:00
VIKING
9be1decbb4 refresh patches 2025-03-01 17:17:17 +08:00
VIKING
1bd4b80529 Merge remote-tracking branch 'upstream/master' 2025-02-28 01:02:07 +08:00
VIKING
201e5f538d Update QCA DTS 2025-02-27 20:32:57 +08:00
VIKING
fb2299bf07 Merge remote-tracking branch 'upstream/master' 2025-02-27 00:20:04 +08:00
VIKINGYFY
acb476b50e Update QCA Source 2025-02-26 17:20:38 +08:00
666 changed files with 63594 additions and 8767 deletions

View File

@ -1,93 +0,0 @@
name: Bug report
description: Create a bug report to help us improve
labels:
- bug
body:
- type: textarea
id: description
attributes:
label: Describe the bug
description: A clear and concise description of the bug.
validations:
required: true
- type: input
id: version
attributes:
label: ImmortalWrt version
description: |
The ImmortalWrt release or commit hash where this bug occurs (use command below).
```. /etc/openwrt_release && echo $DISTRIB_REVISION```
validations:
required: true
- type: input
id: release
attributes:
label: ImmortalWrt release
description: |
The ImmortalWrt release or commit hash where this bug occurs (use command below).
```. /etc/openwrt_release && echo $DISTRIB_RELEASE```
validations:
required: true
- type: input
id: target
attributes:
label: ImmortalWrt target/subtarget
description: |
The ImmortalWrt target and subtarget where this bug is observed (use command below).
```. /etc/openwrt_release && echo $DISTRIB_TARGET```
validations:
required: true
- type: input
id: device
attributes:
label: Device
description: |
The device exhibiting this bug (if unsure, use command below).
```cat /tmp/sysinfo/model```
validations:
required: true
- type: dropdown
id: image_kind
attributes:
label: Image kind
options:
- Official downloaded image
- Self-built image
validations:
required: true
- type: textarea
id: reproduce
attributes:
label: Steps to reproduce
description: Steps to reproduce the reported behaviour.
- type: textarea
id: behaviour
attributes:
label: Actual behaviour
description: A clear and concise description of what actually happens.
- type: textarea
id: expected
attributes:
label: Expected behaviour
description: A clear and concise description of what you expected to happen.
- type: textarea
id: additional
attributes:
label: Additional info
description: Add any additional info you think might be helfpul.
- type: textarea
id: diffconfig
attributes:
label: Diffconfig
description: |
In case of a self-built image, please attach diffconfig.
```./scripts/diffconfig.sh```
render: text
- type: checkboxes
id: terms
attributes:
label: Terms
description: By submitting this issue, you agree to the terms below.
options:
- label: I am reporting an issue for ImmortalWrt, not an unsupported fork.
required: true

View File

@ -1,9 +0,0 @@
---
blank_issues_enabled: true
contact_links:
- name: ImmortalWrt community
url: https://t.me/ctcgfw_openwrt_discuss
about: Consider reaching out to our community to get help. ImmortalWrt is a complex software project with many pitfalls; there is a good chance someone can help you solve your issue in no time.
- name: OpenWrt documentation
url: https://openwrt.org/docs/start
about: The OpenWrt documentation contains a lot of valuable information.

64
.github/workflows/Update-Athena-LED.yml vendored Normal file
View File

@ -0,0 +1,64 @@
name: Update-Athena-LED
on:
workflow_dispatch:
schedule:
- cron: 0 0 * * 0
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
permissions: write-all
jobs:
cleanup:
runs-on: ubuntu-22.04
steps:
- name: Delete old Releases and Workflows
uses: ophub/delete-releases-workflows@main
with:
gh_token: ${{secrets.GITHUB_TOKEN}}
delete_workflows: true
workflows_keep_day: 0
update:
runs-on: ubuntu-22.04
needs: cleanup
steps:
- name: Checkout Projects
uses: actions/checkout@main
- name: Update Athena LED
run: |
cd ./package/emortal/
PKG_NAME=luci-app-athena-led
LOCAL_HASH=$(cat "./$PKG_NAME/.latest_commit" 2>/dev/null || echo "none")
REMOTE_HASH=$(curl -sL https://api.github.com/repos/NONGFAH/luci-app-athena-led/commits/main | jq -r '.sha' | cut -c1-8)
if [[ "$LOCAL_HASH" != "$REMOTE_HASH" ]]; then
rm -rf ./$PKG_NAME
curl -sL -o ./athena-led.zip https://github.com/NONGFAH/luci-app-athena-led/archive/refs/heads/main.zip
unzip ./athena-led.zip -d ./
mv ./luci-app-athena-led-main ./$PKG_NAME && rm -rf ./athena-led.zip
chmod +x -R ./$PKG_NAME/root/usr/sbin/* && chmod +x -R ./$PKG_NAME/root/etc/init.d/*
echo "$PKG_NAME has been updated to $REMOTE_HASH!"
echo "$REMOTE_HASH" > "./$PKG_NAME/.latest_commit"
echo "PKG_NAME=$PKG_NAME" >> "$GITHUB_ENV"
echo "REMOTE_HASH=$REMOTE_HASH" >> "$GITHUB_ENV"
else
echo "$PKG_NAME is already the latest!"
fi
[ -z "$(git status -s)" ] || echo -e "CHANGE_STAT=1" >> "$GITHUB_ENV"
- name: Commit Changes
if: ${{ env.CHANGE_STAT }}
run: |
git config --local user.name "github-actions[bot]"
git config --local user.email "<github-actions[bot]@users.noreply.github.com>"
git add .
git commit -m "${{env.PKG_NAME}}: update version to ${{env.REMOTE_HASH}}"
git push -f origin HEAD:main

View File

@ -38,3 +38,5 @@ source "target/sdk/Config.in"
source "target/toolchain/Config.in"
source "tmp/.config-package.in"
source "config/Config-ipq.in"

View File

@ -1,93 +1,15 @@
<img src="https://avatars.githubusercontent.com/u/53193414?s=200&v=4" alt="logo" width="200" height="200" align="right">
# 分支说明
main 为高通专用无法编译其他平台带满血NSS驱动。
# Project ImmortalWrt
owrt 为多平台通用可编译高通平台但没有NSS驱动。
ImmortalWrt is a fork of [OpenWrt](https://openwrt.org), with more packages ported, more devices supported, default optimized profiles and localization modifications for mainland China users.<br/>
Compared to upstream, we allow to use (non-upstreamable) modifications/hacks to provide better feature/performance/support.
# 自用 ImmortalWRT
高通部分源码取自以下项目:
Default login address: http://192.168.1.1 or http://immortalwrt.lan, username: __root__, password: _none_.
https://github.com/JiaY-shi/openwrt.git
## Download
Built firmware images are available for many architectures and come with a package selection to be used as WiFi home router. To quickly find a factory image usable to migrate from a vendor stock firmware to ImmortalWrt, try the *Firmware Selector*.
https://github.com/LiBwrt/openwrt-6.x.git
- [ImmortalWrt Firmware Selector](https://firmware-selector.immortalwrt.org/)
https://github.com/qosmio/openwrt-ipq.git
If your device is supported, please follow the **Info** link to see install instructions or consult the support resources listed below.
## Development
To build your own firmware you need a GNU/Linux, BSD or macOS system (case sensitive filesystem required). Cygwin is unsupported because of the lack of a case sensitive file system.<br/>
### Requirements
To build with this project, Debian 11 is preferred. And you need use the CPU based on AMD64 architecture, with at least 4GB RAM and 25 GB available disk space. Make sure the __Internet__ is accessible.
The following tools are needed to compile ImmortalWrt, the package names vary between distributions.
- Here is an example for Debian/Ubuntu users:<br/>
- Method 1:
<details>
<summary>Setup dependencies via APT</summary>
```bash
sudo apt update -y
sudo apt full-upgrade -y
sudo apt install -y ack antlr3 asciidoc autoconf automake autopoint binutils bison build-essential \
bzip2 ccache clang cmake cpio curl device-tree-compiler ecj fastjar flex gawk gettext gcc-multilib \
g++-multilib git gnutls-dev gperf haveged help2man intltool lib32gcc-s1 libc6-dev-i386 libelf-dev \
libglib2.0-dev libgmp3-dev libltdl-dev libmpc-dev libmpfr-dev libncurses-dev libpython3-dev \
libreadline-dev libssl-dev libtool libyaml-dev libz-dev lld llvm lrzsz mkisofs msmtp nano \
ninja-build p7zip p7zip-full patch pkgconf python3 python3-pip python3-ply python3-docutils \
python3-pyelftools qemu-utils re2c rsync scons squashfs-tools subversion swig texinfo uglifyjs \
upx-ucl unzip vim wget xmlto xxd zlib1g-dev zstd
```
</details>
- Method 2:
```bash
sudo bash -c 'bash <(curl -s https://build-scripts.immortalwrt.org/init_build_environment.sh)'
```
Note:
- Do everything as an unprivileged user, not root, without sudo.
- Using CPUs based on other architectures should be fine to compile ImmortalWrt, but more hacks are needed - No warranty at all.
- You must __not__ have spaces or non-ascii characters in PATH or in the work folders on the drive.
- If you're using Windows Subsystem for Linux (or WSL), removing Windows folders from PATH is required, please see [Build system setup WSL](https://openwrt.org/docs/guide-developer/build-system/wsl) documentation.
- Using macOS as the host build OS is __not__ recommended. No warranty at all. You can get tips from [Build system setup macOS](https://openwrt.org/docs/guide-developer/build-system/buildroot.exigence.macosx) documentation.
- For more details, please see [Build system setup](https://openwrt.org/docs/guide-developer/build-system/install-buildsystem) documentation.
### Quickstart
1. Run `git clone -b <branch> --single-branch --filter=blob:none https://github.com/immortalwrt/immortalwrt` to clone the source code.
2. Run `cd immortalwrt` to enter source directory.
3. Run `./scripts/feeds update -a` to obtain all the latest package definitions defined in feeds.conf / feeds.conf.default
4. Run `./scripts/feeds install -a` to install symlinks for all obtained packages into package/feeds/
5. Run `make menuconfig` to select your preferred configuration for the toolchain, target system & firmware packages.
6. Run `make` to build your firmware. This will download all sources, build the cross-compile toolchain and then cross-compile the GNU/Linux kernel & all chosen applications for your target system.
### Related Repositories
The main repository uses multiple sub-repositories to manage packages of different categories. All packages are installed via the OpenWrt package manager called opkg. If you're looking to develop the web interface or port packages to ImmortalWrt, please find the fitting repository below.
- [LuCI Web Interface](https://github.com/immortalwrt/luci): Modern and modular interface to control the device via a web browser.
- [ImmortalWrt Packages](https://github.com/immortalwrt/packages): Community repository of ported packages.
- [OpenWrt Routing](https://github.com/openwrt/routing): Packages specifically focused on (mesh) routing.
- [OpenWrt Video](https://github.com/openwrt/video): Packages specifically focused on display servers and clients (Xorg and Wayland).
## Support Information
For a list of supported devices see the [OpenWrt Hardware Database](https://openwrt.org/supported_devices)
### Documentation
- [Quick Start Guide](https://openwrt.org/docs/guide-quick-start/start)
- [User Guide](https://openwrt.org/docs/guide-user/start)
- [Developer Documentation](https://openwrt.org/docs/guide-developer/start)
- [Technical Reference](https://openwrt.org/docs/techref/start)
### Support Community
- Support Chat: group [@ctcgfw_openwrt_discuss](https://t.me/ctcgfw_openwrt_discuss) on [Telegram](https://telegram.org/).
- Support Chat: group [#immortalwrt](https://matrix.to/#/#immortalwrt:matrix.org) on [Matrix](https://matrix.org/).
## License
ImmortalWrt is licensed under [GPL-2.0-only](https://spdx.org/licenses/GPL-2.0-only.html).
## Acknowledgements
<table>
<tr>
<td><a href="https://dlercloud.com/"><img src="https://user-images.githubusercontent.com/22235437/111103249-f9ec6e00-8588-11eb-9bfc-67cc55574555.png" width="183" height="52" border="0" alt="Dler Cloud"></a></td>
<td><a href="https://www.jetbrains.com/"><img src="https://resources.jetbrains.com/storage/products/company/brand/logos/jb_square.png" width="120" height="120" border="0" alt="JetBrains Black Box Logo logo"></a></td>
<td><a href="https://sourceforge.net/"><img src="https://sourceforge.net/sflogo.php?type=17&group_id=3663829" alt="SourceForge" width=200></a></td>
</tr>
</table>
https://github.com/King-Of-Knights/openwrt-6.x.git

145
config/Config-ipq.in Normal file
View File

@ -0,0 +1,145 @@
# vim: set ft=kconfig
menu "Qualcomm IPQ Options"
comment "Kernel build options"
choice KERNEL_IPQ_MEM_PROFILE
prompt "IPQ memory profile"
default IPQ_MEM_PROFILE_1024
config IPQ_MEM_PROFILE_1024
bool "1024"
config IPQ_MEM_PROFILE_512
bool "512"
config IPQ_MEM_PROFILE_256
bool "256"
endchoice
config KERNEL_IPQ_MEM_PROFILE
int
default 1024 if IPQ_MEM_PROFILE_1024
default 512 if IPQ_MEM_PROFILE_512
default 256 if IPQ_MEM_PROFILE_256
help
This option select memory profile to used, which defines
the reserved memory configuration used in device tree
config KERNEL_SKB_RECYCLER
bool "Generic SKB recycling"
default y if KERNEL_IPQ_MEM_PROFILE > 256
choice KERNEL_SKB_RECYCLE_SIZE
prompt "SKB recycler size"
default SKB_RECYCLE_SIZE_2304
default SKB_RECYCLE_SIZE_1856 if KERNEL_IPQ_MEM_PROFILE < 1024
depends on KERNEL_SKB_RECYCLER
config SKB_RECYCLE_SIZE_1856
bool "1856"
config SKB_RECYCLE_SIZE_2304
bool "2304"
endchoice
config KERNEL_SKB_RECYCLE_SIZE
int
depends on KERNEL_SKB_RECYCLER
default 2304 if SKB_RECYCLE_SIZE_2304
default 1856 if SKB_RECYCLE_SIZE_1856
help
SKB recycler default size
config KERNEL_SKB_RECYCLER_MULTI_CPU
bool "Cross-CPU recycling for CPU-locked workloads"
depends on KERNEL_SKB_RECYCLER
default y
config KERNEL_SKB_RECYCLER_PREALLOC
bool "Enable preallocation of SKBs (For SFE not NSS)"
depends on KERNEL_SKB_RECYCLER
default n
help
NOTE: This is primarily for platforms utilizing SFE (Shortcut Forwarding Engine)
and not NSS (Network Subsystem) offload.
NSS offload platforms mostly utilize the SKB recycling feature when managing memory.
Mostly when to "reclaim" it.
This option enables preallocation of SKBs.
The default is '16384' which means 16384 x 4096 (Size of SKB) = 64MB.
config KERNEL_SKB_RECYCLE_MAX_PREALLOC_SKBS
int "Number of SKBs to be preallocated"
depends on KERNEL_SKB_RECYCLER_PREALLOC
default 16384
config KERNEL_SKB_FIXED_SIZE_2K
bool "SKB size fixed at 2K"
default n
default y if KERNEL_IPQ_MEM_PROFILE < 512
help
SKB size fixed at 2K. Primarily for platforms with less than 512MB memory.
config KERNEL_ALLOC_SKB_PAGE_FRAG_DISABLE
depends on KERNEL_SKB_RECYCLER
bool "Disable alloc skb page frag"
default n
choice KERNEL_PREEMPTION
prompt "Kernel preemption level"
default KERNEL_PREEMPT
config KERNEL_PREEMPT_NONE
bool "No Forced Preemption (Server)"
help
This is the traditional Linux preemption model, geared towards
throughput. It will still provide good latencies most of the time,
but there are no guarantees and occasional longer delays are
possible.
Select this option if you are building a kernel for a server or
scientific/computation system, or if you want to maximize the
raw processing power of the kernel, irrespective of scheduling
latencies.
config KERNEL_PREEMPT_NONE_BUILD
depends on KERNEL_PREEMPT_NONE
bool
default y
config KERNEL_PREEMPT
bool "Preemptible Kernel (Low-Latency)"
help
This option reduces the latency of the kernel by making
all kernel code (that is not executing in a critical section)
preemptible. This allows reaction to interactive events by
permitting a low priority process to be preempted involuntarily
even if it is in kernel mode executing a system call and would
otherwise not be about to reach a natural preemption point.
This allows applications to run more 'smoothly' even when the
system is under load, at the cost of slightly lower throughput
and a slight runtime overhead to kernel code.
Select this if you are building a kernel for a desktop or
embedded system with latency requirements in the milliseconds
range.
if KERNEL_PREEMPT
config KERNEL_PREEMPT_RCU
bool "Preemptible RCU"
default y
select KERNEL_PREEMPT_COUNT
help
This option selects the RCU implementation that is
designed for very large SMP systems with hundreds or
thousands of CPUs, but for which real-time response
is also required. It also scales down nicely to
smaller systems.
Select this option if you are unsure.
endif
endchoice
endmenu

View File

@ -445,7 +445,7 @@ config KERNEL_DEBUG_INFO
config KERNEL_DEBUG_INFO_BTF
bool "Enable additional BTF type information"
default y if (TARGET_armsr || TARGET_bcm27xx || TARGET_ipq806x_chromium || TARGET_mediatek_filogic || TARGET_mvebu_cortexa53 || TARGET_mvebu_cortexa72 || TARGET_qualcommax_ipq60xx || TARGET_rockchip || TARGET_sunxi || TARGET_x86_64) && BUILDBOT
default y if (TARGET_armsr || TARGET_bcm27xx || TARGET_ipq806x_chromium || TARGET_mediatek_filogic || TARGET_mvebu_cortexa53 || TARGET_mvebu_cortexa72 || TARGET_rockchip || TARGET_sunxi || TARGET_x86_64) && BUILDBOT
depends on !HOST_OS_MACOS
depends on KERNEL_DEBUG_INFO && !KERNEL_DEBUG_INFO_REDUCED
select DWARVES
@ -473,7 +473,7 @@ config KERNEL_MODULE_ALLOW_BTF_MISMATCH
config KERNEL_DEBUG_INFO_REDUCED
bool "Reduce debugging information"
default y if !(TARGET_armsr || TARGET_bcm27xx || TARGET_ipq806x_chromium || TARGET_mediatek_filogic || TARGET_mvebu_cortexa53 || TARGET_mvebu_cortexa72 || TARGET_qualcommax_ipq60xx || TARGET_rockchip || TARGET_sunxi || TARGET_x86_64) || !BUILDBOT
default y if !(TARGET_armsr || TARGET_bcm27xx || TARGET_ipq806x_chromium || TARGET_mediatek_filogic || TARGET_mvebu_cortexa53 || TARGET_mvebu_cortexa72 || TARGET_rockchip || TARGET_sunxi || TARGET_x86_64) || !BUILDBOT
depends on KERNEL_DEBUG_INFO
help
If you say Y here gcc is instructed to generate less debugging

View File

@ -1,3 +1,5 @@
src-git nss_packages https://github.com/qosmio/nss-packages.git
src-git sqm_scripts_nss https://github.com/qosmio/sqm-scripts-nss.git
src-git packages https://github.com/immortalwrt/packages.git
src-git luci https://github.com/immortalwrt/luci.git
src-git routing https://github.com/openwrt/routing.git

View File

@ -1,30 +1,40 @@
BPF_DEPENDS := @HAS_BPF_TOOLCHAIN +@NEED_BPF_TOOLCHAIN
LLVM_VER:=
CLANG_MIN_VER:=12
ifneq ($(CONFIG_USE_LLVM_HOST),)
find-llvm-tool=$(firstword $(shell PATH='$(BPF_PATH)' command -v $(1) || echo '$(firstword $(1))-not-found'))
BPF_TOOLCHAIN_HOST_PATH:=$(call qstrip,$(CONFIG_BPF_TOOLCHAIN_HOST_PATH))
ifneq ($(BPF_TOOLCHAIN_HOST_PATH),)
BPF_PATH:=$(BPF_TOOLCHAIN_HOST_PATH)/bin:$(PATH)
else
BPF_PATH:=$(PATH)
endif
CLANG:=$(firstword $(shell PATH='$(BPF_PATH)' command -v clang clang-13 clang-12 clang-11))
CLANG:=$(call find-llvm-tool,clang clang-13 clang-12)
LLVM_VER:=$(subst clang,,$(notdir $(CLANG)))
endif
ifneq ($(CONFIG_USE_LLVM_PREBUILT),)
CLANG:=$(TOPDIR)/llvm-bpf/bin/clang
endif
ifneq ($(CONFIG_USE_LLVM_BUILD),)
CLANG:=$(STAGING_DIR_HOST)/llvm-bpf/bin/clang
endif
LLVM_PATH:=$(dir $(CLANG))
LLVM_LLC:=$(LLVM_PATH)/llc$(LLVM_VER)
LLVM_DIS:=$(LLVM_PATH)/llvm-dis$(LLVM_VER)
LLVM_OPT:=$(LLVM_PATH)/opt$(LLVM_VER)
LLVM_STRIP:=$(LLVM_PATH)/llvm-strip$(LLVM_VER)
BPF_PATH:=$(dir $(CLANG)):$(BPF_PATH)
LLVM_LLC:=$(call find-llvm-tool,llc$(LLVM_VER))
LLVM_DIS:=$(call find-llvm-tool,llvm-dis$(LLVM_VER))
LLVM_OPT:=$(call find-llvm-tool,opt$(LLVM_VER))
LLVM_STRIP:=$(call find-llvm-tool,llvm-strip$(LLVM_VER))
else
LLVM_PATH:=/invalid
ifneq ($(CONFIG_USE_LLVM_PREBUILT),)
LLVM_PATH:=$(TOPDIR)/llvm-bpf/bin
endif
ifneq ($(CONFIG_USE_LLVM_BUILD),)
LLVM_PATH:=$(STAGING_DIR_HOST)/llvm-bpf/bin
endif
CLANG:=$(LLVM_PATH)/clang
LLVM_LLC:=$(LLVM_PATH)/llc
LLVM_DIS:=$(LLVM_PATH)/llvm-dis
LLVM_OPT:=$(LLVM_PATH)/opt
LLVM_STRIP:=$(LLVM_PATH)/llvm-strip
endif
BPF_KARCH:=mips
BPF_ARCH:=mips$(if $(CONFIG_ARCH_64BIT),64)$(if $(CONFIG_BIG_ENDIAN),,el)

View File

@ -1,2 +1,2 @@
LINUX_VERSION-6.6 = .85
LINUX_KERNEL_HASH-6.6.85 = 5ebaccf4ca3428cd26817bae62171f4efd270eed866a3e3d0a1d9e970b7b7529
LINUX_VERSION-6.6 = .87
LINUX_KERNEL_HASH-6.6.87 = 8957e5c2dacdbc47a16dbf1f6303ca7088409be6197a3881f752313275357ac6

View File

@ -290,8 +290,8 @@ ifeq ($(DUMP),1)
CPU_CFLAGS_archs = -mcpu=archs
endif
ifeq ($(ARCH),riscv64)
CPU_TYPE ?= riscv64
CPU_CFLAGS_riscv64:=-mabi=lp64d -march=rv64imafdc
CPU_TYPE ?= generic
CPU_CFLAGS_generic:=-mabi=lp64d -march=rv64gc
endif
ifeq ($(ARCH),loongarch64)
CPU_TYPE ?= generic

View File

@ -1,12 +1,20 @@
PKG_NAME ?= trusted-firmware-a
PKG_CPE_ID ?= cpe:/a:arm:trusted_firmware-a
ifndef PKG_SOURCE_PROTO
PKG_SOURCE = trusted-firmware-a-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/TrustedFirmware-A/trusted-firmware-a/tar.gz/v$(PKG_VERSION)?
PKG_LTS ?=
ifneq ($(PKG_LTS),)
PKG_VERSION_PREFIX:=lts-v
PKG_BUILD_DIR = $(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION_PREFIX)$(PKG_VERSION)
else
PKG_VERSION_PREFIX:=v
PKG_BUILD_DIR = $(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
endif
PKG_BUILD_DIR = $(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
ifndef PKG_SOURCE_PROTO
PKG_SOURCE = trusted-firmware-a-$(PKG_VERSION_PREFIX)$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/TrustedFirmware-A/trusted-firmware-a/tar.gz/$(PKG_VERSION_PREFIX)$(PKG_VERSION)?
endif
PKG_TARGETS := bin
PKG_FLAGS:=nonshared
@ -83,7 +91,7 @@ define Build/Compile/Trusted-Firmware-A
OPENSSL_DIR=$(STAGING_DIR_HOST) \
$(if $(DTC),DTC="$(DTC)") \
PLAT=$(PLAT) \
BUILD_STRING="ImmortalWrt v$(PKG_VERSION)-$(PKG_RELEASE) ($(VARIANT))" \
BUILD_STRING="ImmortalWrt $(PKG_VERSION_PREFIX)$(PKG_VERSION)-$(PKG_RELEASE) ($(VARIANT))" \
$(TFA_MAKE_FLAGS)
endef

View File

@ -312,8 +312,8 @@ generate_static_system() {
delete system.@system[0]
add system system
set system.@system[-1].hostname='ImmortalWrt'
set system.@system[-1].timezone='GMT0'
set system.@system[-1].zonename='UTC'
set system.@system[-1].timezone='CST-8'
set system.@system[-1].zonename='Asia/Shanghai'
set system.@system[-1].ttylogin='0'
set system.@system[-1].log_size='128'
set system.@system[-1].urandom_seed='0'
@ -322,10 +322,10 @@ generate_static_system() {
set system.ntp='timeserver'
set system.ntp.enabled='1'
set system.ntp.enable_server='0'
add_list system.ntp.server='time1.apple.com'
add_list system.ntp.server='time1.google.com'
add_list system.ntp.server='time.cloudflare.com'
add_list system.ntp.server='pool.ntp.org'
add_list system.ntp.server='ntp.tencent.com'
add_list system.ntp.server='ntp.aliyun.com'
add_list system.ntp.server='ntp.ntsc.ac.cn'
add_list system.ntp.server='cn.ntp.org.cn'
EOF
if json_is_a system object; then

View File

0
package/base-files/files/etc/hotplug.d/leds/00-init Normal file → Executable file
View File

0
package/base-files/files/etc/hotplug.d/net/00-sysctl Normal file → Executable file
View File

0
package/base-files/files/etc/sysctl.d/10-default.conf Normal file → Executable file
View File

View File

View File

View File

View File

View File

View File

@ -1,5 +1,4 @@
# Copyright (C) 2021 OpenWrt.org
#
. /lib/functions.sh
@ -29,8 +28,7 @@ emmc_upgrade_tar() {
sync
}
[ "$has_kernel" = 1 -a "$EMMC_KERN_DEV" ] &&
export EMMC_KERNEL_BLOCKS=$(($(tar xf "$tar_file" ${board_dir}/kernel -O | dd of="$EMMC_KERN_DEV" bs=512 2>&1 | grep "records out" | cut -d' ' -f1)))
[ "$has_kernel" = 1 -a "$EMMC_KERN_DEV" ] && export EMMC_KERNEL_BLOCKS=$(($(tar xf "$tar_file" ${board_dir}/kernel -O | dd of="$EMMC_KERN_DEV" bs=512 2>&1 | grep "records out" | cut -d' ' -f1)))
if [ -z "$UPGRADE_BACKUP" ]; then
if [ "$EMMC_DATA_DEV" ]; then

View File

@ -43,6 +43,7 @@ endef
define Trusted-Firmware-A/Default
BUILD_TARGET:=layerscape
BUILD_SUBTARGET:=armv8_64b
BUILD_DEVICES:=fsl_$(1)
DEPENDS:=+layerscape-rcw +u-boot-fsl_$(1)
endef

View File

@ -28,7 +28,7 @@ endef
define U-Boot/qca9558_nec_aterm
NAME:=NEC Aterm series (QCA9558)
BUILD_SUBTARGET:= generic
BUILD_DEVICES:=nec_wg1400hp nec_wg1800hp nec_wg1800hp2
BUILD_DEVICES:=nec_wg1400hp nec_wg1800hp nec_wg1800hp2 nec_wg2200hp
UBOOT_CONFIG:=nec_qca9558_aterm
endef

View File

@ -435,6 +435,18 @@ define U-Boot/mt7981_livinet_zr-3020
DEPENDS:=+trusted-firmware-a-mt7981-spim-nand-ddr3
endef
define U-Boot/mt7981_netis_nx31
NAME:=netis NX31
BUILD_SUBTARGET:=filogic
BUILD_DEVICES:=netis_nx31
UBOOT_CONFIG:=mt7981_netis_nx31
UBOOT_IMAGE:=u-boot.fip
BL2_BOOTDEV:=spim-nand
BL2_SOC:=mt7981
BL2_DDRTYPE:=ddr3
DEPENDS:=+trusted-firmware-a-mt7981-spim-nand-ddr3
endef
define U-Boot/mt7981_nokia_ea0326gmp
NAME:=Nokia EA0326GMP
BUILD_SUBTARGET:=filogic
@ -1006,6 +1018,7 @@ UBOOT_TARGETS := \
mt7981_konka_komi-a31-emmc \
mt7981_konka_komi-a31-nor \
mt7981_livinet_zr-3020 \
mt7981_netis_nx31 \
mt7981_nokia_ea0326gmp \
mt7981_openwrt_one-snand \
mt7981_openwrt_one-nor \

View File

@ -0,0 +1,334 @@
--- /dev/null
+++ b/configs/mt7981_netis_nx31_defconfig
@@ -0,0 +1,106 @@
+CONFIG_ARM=y
+CONFIG_SYS_HAS_NONCACHED_MEMORY=y
+CONFIG_POSITION_INDEPENDENT=y
+CONFIG_ARCH_MEDIATEK=y
+CONFIG_TEXT_BASE=0x41e00000
+CONFIG_SYS_MALLOC_F_LEN=0x4000
+CONFIG_NR_DRAM_BANKS=1
+CONFIG_DEFAULT_DEVICE_TREE="mt7981-netis_nx31"
+CONFIG_OF_LIBFDT_OVERLAY=y
+CONFIG_TARGET_MT7981=y
+CONFIG_SYS_LOAD_ADDR=0x46000000
+CONFIG_PRE_CON_BUF_ADDR=0x4007ef00
+CONFIG_DEBUG_UART_BASE=0x11002000
+CONFIG_DEBUG_UART_CLOCK=40000000
+CONFIG_DEBUG_UART=y
+CONFIG_FIT=y
+CONFIG_BOOTDELAY=30
+CONFIG_AUTOBOOT_KEYED=y
+CONFIG_AUTOBOOT_MENU_SHOW=y
+CONFIG_DEFAULT_FDT_FILE="mediatek/mt7981-netis_nx31.dtb"
+CONFIG_LOGLEVEL=7
+CONFIG_PRE_CONSOLE_BUFFER=y
+CONFIG_LOG=y
+CONFIG_BOARD_LATE_INIT=y
+CONFIG_HUSH_PARSER=y
+CONFIG_SYS_PROMPT="MT7981> "
+CONFIG_CMD_CPU=y
+CONFIG_CMD_LICENSE=y
+CONFIG_CMD_BOOTMENU=y
+CONFIG_CMD_ASKENV=y
+CONFIG_CMD_ERASEENV=y
+CONFIG_CMD_ENV_FLAGS=y
+CONFIG_CMD_STRINGS=y
+CONFIG_CMD_DM=y
+CONFIG_CMD_GPIO=y
+CONFIG_CMD_GPT=y
+CONFIG_CMD_MTD=y
+CONFIG_CMD_PART=y
+CONFIG_CMD_TFTPSRV=y
+CONFIG_CMD_RARP=y
+CONFIG_CMD_CDP=y
+CONFIG_CMD_SNTP=y
+CONFIG_CMD_LINK_LOCAL=y
+CONFIG_CMD_DHCP=y
+CONFIG_CMD_DNS=y
+CONFIG_CMD_PING=y
+CONFIG_CMD_PXE=y
+CONFIG_CMD_CACHE=y
+CONFIG_CMD_PSTORE=y
+CONFIG_CMD_PSTORE_MEM_ADDR=0x42ff0000
+CONFIG_CMD_UUID=y
+CONFIG_CMD_HASH=y
+CONFIG_CMD_SMC=y
+CONFIG_CMD_UBI=y
+CONFIG_CMD_UBI_RENAME=y
+CONFIG_OF_EMBED=y
+CONFIG_ENV_OVERWRITE=y
+CONFIG_ENV_IS_IN_UBI=y
+CONFIG_SYS_REDUNDAND_ENVIRONMENT=y
+CONFIG_ENV_UBI_PART="ubi"
+CONFIG_ENV_UBI_VOLUME="ubootenv"
+CONFIG_ENV_UBI_VOLUME_REDUND="ubootenv2"
+CONFIG_SYS_RELOC_GD_ENV_ADDR=y
+CONFIG_USE_DEFAULT_ENV_FILE=y
+CONFIG_DEFAULT_ENV_FILE="defenvs/netis_nx31_env"
+CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
+CONFIG_VERSION_VARIABLE=y
+CONFIG_NETCONSOLE=y
+CONFIG_USE_IPADDR=y
+CONFIG_IPADDR="192.168.1.1"
+CONFIG_USE_SERVERIP=y
+CONFIG_SERVERIP="192.168.1.254"
+CONFIG_NET_RANDOM_ETHADDR=y
+CONFIG_BUTTON=y
+CONFIG_BUTTON_GPIO=y
+CONFIG_CLK=y
+CONFIG_GPIO_HOG=y
+CONFIG_LED=y
+CONFIG_LED_BLINK=y
+CONFIG_LED_GPIO=y
+# CONFIG_MMC is not set
+CONFIG_MTD=y
+CONFIG_DM_MTD=y
+CONFIG_MTD_SPI_NAND=y
+CONFIG_MTD_UBI_FASTMAP=y
+CONFIG_PHY_FIXED=y
+CONFIG_MEDIATEK_ETH=y
+CONFIG_PHY=y
+CONFIG_PHY_MTK_TPHY=y
+CONFIG_PINCTRL=y
+CONFIG_PINCONF=y
+CONFIG_PINCTRL_MT7981=y
+CONFIG_POWER_DOMAIN=y
+CONFIG_MTK_POWER_DOMAIN=y
+CONFIG_DM_REGULATOR=y
+CONFIG_DM_REGULATOR_FIXED=y
+CONFIG_DM_REGULATOR_GPIO=y
+CONFIG_RAM=y
+CONFIG_DM_SERIAL=y
+CONFIG_SERIAL_RX_BUFFER=y
+CONFIG_MTK_SERIAL=y
+CONFIG_SPI=y
+CONFIG_DM_SPI=y
+CONFIG_MTK_SPIM=y
+CONFIG_ZSTD=y
+CONFIG_HEXDUMP=y
--- /dev/null
+++ b/arch/arm/dts/mt7981-netis_nx31.dts
@@ -0,0 +1,162 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Copyright (c) 2025
+ * Author: Mikhail Zhilkin <csharper2005@gmail.com>
+ */
+
+/dts-v1/;
+#include "mt7981.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/linux-event-codes.h>
+
+/ {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ model = "netis NX31";
+ compatible = "netis,nx31", "mediatek,mt7981";
+
+ chosen {
+ stdout-path = &uart0;
+ tick-timer = &timer0;
+ };
+
+ memory@40000000 {
+ device_type = "memory";
+ reg = <0x40000000 0x10000000>;
+ };
+
+ keys {
+ compatible = "gpio-keys";
+
+ button-0 {
+ label = "mesh";
+ linux,code = <BTN_0>;
+ gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
+ };
+
+ button-1 {
+ label = "reset";
+ linux,code = <KEY_RESTART>;
+ gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ leds {
+ compatible = "gpio-leds";
+
+ led-0 {
+ label = "blue:wlan2g";
+ gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
+ };
+
+ led-1 {
+ label = "blue:status";
+ gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
+ };
+
+ led-2 {
+ label = "blue:wan";
+ gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
+ };
+
+ led-3 {
+ label = "blue:wlan5g";
+ gpios = <&gpio 34 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&uart0 {
+ mediatek,force-highspeed;
+ status = "okay";
+};
+
+&eth {
+ status = "okay";
+ mediatek,gmac-id = <0>;
+ phy-mode = "2500base-x";
+ mediatek,switch = "mt7531";
+ reset-gpios = <&gpio 39 GPIO_ACTIVE_HIGH>;
+
+ fixed-link {
+ speed = <2500>;
+ full-duplex;
+ };
+};
+
+&pinctrl {
+ spi_flash_pins: spi0-pins-func-1 {
+ mux {
+ function = "flash";
+ groups = "spi0", "spi0_wp_hold";
+ };
+
+ conf-pu {
+ pins = "SPI0_CS", "SPI0_HOLD", "SPI0_WP";
+ drive-strength = <MTK_DRIVE_8mA>;
+ bias-pull-up = <MTK_PUPD_SET_R1R0_11>;
+ };
+
+ conf-pd {
+ pins = "SPI0_CLK", "SPI0_MOSI", "SPI0_MISO";
+ drive-strength = <MTK_DRIVE_8mA>;
+ bias-pull-down = <MTK_PUPD_SET_R1R0_11>;
+ };
+ };
+};
+
+&spi0 {
+ #address-cells = <1>;
+ #size-cells = <0>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&spi_flash_pins>;
+ status = "okay";
+ must_tx;
+ enhance_timing;
+ dma_ext;
+ ipm_design;
+ support_quad;
+ tick_dly = <2>;
+ sample_sel = <0>;
+
+ spi_nand@0 {
+ compatible = "spi-nand";
+ reg = <0>;
+ spi-max-frequency = <52000000>;
+
+ partitions {
+ compatible = "fixed-partitions";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ partition@0 {
+ label = "BL2";
+ reg = <0x0 0x100000>;
+ };
+
+ partition@100000 {
+ label = "u-boot-env (unused)";
+ reg = <0x100000 0x80000>;
+ };
+
+ partition@160000 {
+ label = "Factory";
+ reg = <0x180000 0x200000>;
+ };
+
+ partition@380000 {
+ label = "FIP";
+ reg = <0x380000 0x200000>;
+ };
+
+ partition@580000 {
+ label = "ubi";
+ reg = <0x580000 0x7a80000>;
+ };
+ };
+ };
+};
+
+&watchdog {
+ status = "disabled";
+};
--- /dev/null
+++ b/defenvs/netis_nx31_env
@@ -0,0 +1,57 @@
+ipaddr=192.168.1.1
+serverip=192.168.1.254
+loadaddr=0x46000000
+console=earlycon=uart8250,mmio32,0x11002000 console=ttyS0
+bootcmd=run check_buttons ; if pstore check ; then run boot_recovery ; else run boot_ubi ; fi
+bootconf=config-1
+bootdelay=0
+bootfile=immortalwrt-mediatek-filogic-netis_nx31-initramfs-recovery.itb
+bootfile_bl2=immortalwrt-mediatek-filogic-netis_nx31-preloader.bin
+bootfile_fip=immortalwrt-mediatek-filogic-netis_nx31-bl31-uboot.fip
+bootfile_upg=immortalwrt-mediatek-filogic-netis_nx31-squashfs-sysupgrade.itb
+bootled_status=blue:status
+bootmenu_confirm_return=askenv - Press ENTER to return to menu ; bootmenu 60
+bootmenu_default=0
+bootmenu_delay=0
+bootmenu_title= ( ( ( OpenWrt ) ) )
+bootmenu_0=Initialize environment.=run _firstboot
+bootmenu_0d=Run default boot command.=run boot_default
+bootmenu_1=Boot system via TFTP.=run boot_tftp ; run bootmenu_confirm_return
+bootmenu_2=Boot production system from NAND.=run boot_production ; run bootmenu_confirm_return
+bootmenu_3=Boot recovery system from NAND.=run boot_recovery ; run bootmenu_confirm_return
+bootmenu_4=Load production system via TFTP then write to NAND.=setenv noboot 1 ; setenv replacevol 1 ; run boot_tftp_production ; setenv noboot ; setenv replacevol ; run bootmenu_confirm_return
+bootmenu_5=Load recovery system via TFTP then write to NAND.=setenv noboot 1 ; setenv replacevol 1 ; run boot_tftp_recovery ; setenv noboot ; setenv replacevol ; run bootmenu_confirm_return
+bootmenu_6=Load BL31+U-Boot FIP via TFTP then write to NAND.=run boot_tftp_write_fip ; run bootmenu_confirm_return
+bootmenu_7=Load BL2 preloader via TFTP then write to NAND.=run boot_tftp_write_bl2 ; run bootmenu_confirm_return
+bootmenu_8=Reboot.=reset
+bootmenu_9=Reset all settings to factory defaults.=run reset_factory ; reset
+boot_first=if button reset ; then led $bootled_status on ; run boot_default ; fi ; bootmenu
+boot_default=if env exists flag_recover ; then else run bootcmd ; fi ; run boot_recovery ; setenv replacevol 1 ; run boot_tftp_forever
+boot_production=led $bootled_status on ; run ubi_read_production && bootm $loadaddr#$bootconf ; led bootled_status off
+boot_recovery=led $bootled_status on ; run ubi_read_recovery && bootm $loadaddr#$bootconf ; led bootled_status off
+boot_ubi=run boot_production ; run boot_recovery ; run boot_tftp_forever
+boot_tftp_forever=led $bootled_status on ; while true ; do run boot_tftp ; sleep 1 ; done
+boot_tftp_production=tftpboot $loadaddr $bootfile_upg && env exists replacevol && iminfo $loadaddr && run ubi_write_production ; if env exists noboot ; then else bootm $loadaddr#$bootconf ; fi
+boot_tftp_recovery=tftpboot $loadaddr $bootfile && env exists replacevol && iminfo $loadaddr && run ubi_write_recovery ; if env exists noboot ; then else bootm $loadaddr#$bootconf ; fi
+boot_tftp=tftpboot $loadaddr $bootfile && bootm $loadaddr#$bootconf
+boot_tftp_write_fip=tftpboot $loadaddr $bootfile_fip && run mtd_write_fip && run reset_factory
+boot_tftp_write_bl2=tftpboot $loadaddr $bootfile_bl2 && run mtd_write_bl2
+check_buttons=if button reset ; then run boot_tftp ; fi
+ethaddr_factory=mtd read Factory 0x40080000 0x1e0000 0x20000 && env readmem -b ethaddr 0x4009ef20 0x6 ; setenv ethaddr_factory
+part_default=production
+part_recovery=recovery
+reset_factory=ubi part ubi ; mw $loadaddr 0x0 0x800 ; ubi write $loadaddr ubootenv 0x800 ; ubi write $loadaddr ubootenv2 0x800
+mtd_write_fip=mtd erase FIP && mtd write FIP $loadaddr
+mtd_write_bl2=mtd erase BL2 && mtd write BL2 $loadaddr
+ubi_create_env=ubi check ubootenv || ubi create ubootenv 0x100000 dynamic || run ubi_format ; ubi check ubootenv2 || ubi create ubootenv2 0x100000 dynamic || run ubi_format
+ubi_format=ubi detach ; mtd erase ubi && ubi part ubi ; reset
+ubi_prepare_rootfs=if ubi check rootfs_data ; then else if env exists rootfs_data_max ; then ubi create rootfs_data $rootfs_data_max dynamic || ubi create rootfs_data - dynamic ; else ubi create rootfs_data - dynamic ; fi ; fi
+ubi_read_production=ubi read $loadaddr fit && iminfo $loadaddr && run ubi_prepare_rootfs
+ubi_read_recovery=ubi check recovery && ubi read $loadaddr recovery
+ubi_remove_rootfs=ubi check rootfs_data && ubi remove rootfs_data
+ubi_write_production=ubi check fit && ubi remove fit ; run ubi_remove_rootfs ; ubi create fit $filesize dynamic && ubi write $loadaddr fit $filesize
+ubi_write_recovery=ubi check recovery && ubi remove recovery ; run ubi_remove_rootfs ; ubi create recovery $filesize dynamic && ubi write $loadaddr recovery $filesize
+_init_env=setenv _init_env ; run ubi_create_env ; saveenv ; saveenv
+_firstboot=setenv _firstboot ; run ethaddr_factory ; run _switch_to_menu ; run _init_env ; run boot_first
+_switch_to_menu=setenv _switch_to_menu ; setenv bootdelay 3 ; setenv bootmenu_delay 3 ; setenv bootmenu_0 $bootmenu_0d ; setenv bootmenu_0d ; run _bootmenu_update_title
+_bootmenu_update_title=setenv _bootmenu_update_title ; setenv bootmenu_title "$bootmenu_title $ver"

View File

@ -146,6 +146,20 @@ define U-Boot/nanopi-r4se-rk3399
friendlyarm_nanopi-r4se
endef
define U-Boot/rock-4c-plus-rk3399
$(U-Boot/rk3399/Default)
NAME:=ROCK 4C+
BUILD_DEVICES:= \
radxa_rock-4c-plus
endef
define U-Boot/rock-4se-rk3399
$(U-Boot/rk3399/Default)
NAME:=ROCK 4SE
BUILD_DEVICES:= \
radxa_rock-4se
endef
define U-Boot/rock-pi-4-rk3399
$(U-Boot/rk3399/Default)
NAME:=ROCK Pi 4
@ -389,6 +403,8 @@ UBOOT_TARGETS := \
nanopc-t4-rk3399 \
nanopi-r4s-rk3399 \
nanopi-r4se-rk3399 \
rock-4c-plus-rk3399 \
rock-4se-rk3399 \
rock-pi-4-rk3399 \
rockpro64-rk3399 \
rock-pi-s-rk3308 \

View File

@ -45,6 +45,7 @@ livinet,zr-3020-ubootmod|\
mercusys,mr90x-v1-ubi|\
netcore,n60|\
netcore,n60-pro|\
netis,nx31|\
nokia,ea0326gmp|\
qihoo,360t7|\
routerich,ax3000-ubootmod|\
@ -118,6 +119,7 @@ gatonetworks,gdsp)
glinet,gl-mt3000)
ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x80000" "0x20000"
;;
mercusys,mr80x-v3|\
mercusys,mr90x-v1|\
routerich,ax3000|\
tenbay,wr3000k|\

View File

@ -7,14 +7,30 @@ touch /etc/config/ubootenv
board=$(board_name)
ubootenv_add_mtd() {
local idx="$(find_mtd_index "${1}")"
[ -n "$idx" ] && ubootenv_add_uci_config "/dev/mtd$idx" "${2}" "${3}" "${4}"
}
ubootenv_add_sys_mtd() {
local idx="$(find_mtd_index "${1}")"
[ -n "$idx" ] && ubootenv_add_uci_sys_config "/dev/mtd$idx" "${2}" "${3}" "${4}"
}
ubootenv_add_mmc() {
local mmcpart="$(find_mmc_part "${1}")"
[ -n "$mmcpart" ] && ubootenv_add_uci_config "$mmcpart" "${2}" "${3}" "${4}" "${5}"
}
case "$board" in
linksys,mr5500|\
linksys,mx2000|\
linksys,mx5500|\
linksys,spnmx56)
idx="$(find_mtd_index u_env)"
[ -n "$idx" ] && \
ubootenv_add_uci_config "/dev/mtd$idx" "0x0" "0x40000" "0x20000"
ubootenv_add_mtd "u_env" "0x0" "0x40000" "0x20000"
;;
jdcloud,re-cs-03)
ubootenv_add_mmc "0:APPSBLENV" "0x0" "0x40000" "0x20000"
;;
esac

View File

@ -9,8 +9,17 @@ board=$(board_name)
ubootenv_add_mtd() {
local idx="$(find_mtd_index "${1}")"
[ -n "$idx" ] && \
ubootenv_add_uci_config "/dev/mtd$idx" "${2}" "${3}" "${4}"
[ -n "$idx" ] && ubootenv_add_uci_config "/dev/mtd$idx" "${2}" "${3}" "${4}"
}
ubootenv_add_sys_mtd() {
local idx="$(find_mtd_index "${1}")"
[ -n "$idx" ] && ubootenv_add_uci_sys_config "/dev/mtd$idx" "${2}" "${3}" "${4}"
}
ubootenv_add_mmc() {
local mmcpart="$(find_mmc_part "${1}")"
[ -n "$mmcpart" ] && ubootenv_add_uci_config "$mmcpart" "${2}" "${3}" "${4}" "${5}"
}
case "$board" in
@ -19,21 +28,35 @@ case "$board" in
cambiumnetworks,xe3-4)
ubootenv_add_mtd "0:APPSBLENV" "0x0" "0x10000" "0x10000"
;;
cmiot,ax18|\
qihoo,360v6|\
redmi,ax5|\
xiaomi,ax1800|\
zn,m2|\
glinet,gl-ax1800|\
glinet,gl-axt1800|\
netgear,wax214|\
netgear,wax610|\
netgear,wax610y|\
tplink,eap610od|\
tplink,eap623od-hd-v1)
ubootenv_add_mtd "0:appsblenv" "0x0" "0x40000" "0x20000"
;;
linksys,mr7350|\
linksys,mr7500)
ubootenv_add_mtd "u_env" "0x0" "0x40000" "0x20000"
;;
netgear,wax214|\
netgear,wax610|\
netgear,wax610y|\
tplink,eap610-outdoor)
ubootenv_add_mtd "0:appsblenv" "0x0" "0x40000" "0x20000"
;;
yuncore,fap650)
ubootenv_add_mtd "0:appsblenv" "0x0" "0x10000" "0x10000"
;;
jdcloud,re-ss-01|\
jdcloud,re-cs-02|\
jdcloud,re-cs-07|\
link,nn6000-v1|\
link,nn6000-v2|\
redmi,ax5-jdcloud)
ubootenv_add_mmc "0:APPSBLENV" "0x0" "0x40000" "0x20000"
;;
esac
config_load ubootenv

View File

@ -9,20 +9,17 @@ board=$(board_name)
ubootenv_add_mtd() {
local idx="$(find_mtd_index "${1}")"
[ -n "$idx" ] && \
ubootenv_add_uci_config "/dev/mtd$idx" "${2}" "${3}" "${4}"
[ -n "$idx" ] && ubootenv_add_uci_config "/dev/mtd$idx" "${2}" "${3}" "${4}"
}
ubootenv_add_sys_mtd() {
local idx="$(find_mtd_index "${1}")"
[ -n "$idx" ] && \
ubootenv_add_uci_sys_config "/dev/mtd$idx" "${2}" "${3}" "${4}"
[ -n "$idx" ] && ubootenv_add_uci_sys_config "/dev/mtd$idx" "${2}" "${3}" "${4}"
}
ubootenv_add_mmc() {
local mmcpart="$(find_mmc_part "${1}")"
[ -n "$mmcpart" ] && \
ubootenv_add_uci_config "$mmcpart" "${2}" "${3}" "${4}" "${5}"
[ -n "$mmcpart" ] && ubootenv_add_uci_config "$mmcpart" "${2}" "${3}" "${4}" "${5}"
}
case "$board" in
@ -74,8 +71,9 @@ asus,rt-ax89x|\
qnap,301w)
ubootenv_add_mtd "0:appsblenv" "0x0" "0x20000" "0x20000"
;;
spectrum,sax1v1k)
ubootenv_add_mmc "0:APPSBLENV" "0x0" "0x40000" "0x40000" "1"
spectrum,sax1v1k|\
verizon,cr1000a)
ubootenv_add_mmc "0:APPSBLENV" "0x0" "0x40000" "0x40000"
;;
esac

View File

@ -30,8 +30,6 @@ define Build/Compile
endef
define Package/autocore/install
$(INSTALL_DIR) $(1)/etc/uci-defaults
$(INSTALL_BIN) ./files/60-autocore-reload-rpcd $(1)/etc/uci-defaults/
ifneq ($(filter i386 i686 x86_64, $(ARCH)),)
$(INSTALL_DIR) $(1)/etc/init.d

View File

@ -1,5 +0,0 @@
#!/bin/sh
/etc/init.d/rpcd restart
exit 0

View File

@ -7,7 +7,7 @@ CPUFREQ_PATH="/sys/devices/system/cpu/cpufreq"
THERMAL_PATH="/sys/class/thermal"
cpu_arch="$(awk -F ': ' '/model name/ {print $2}' "$CPUINFO_PATH" | head -n1)"
[ -n "${cpu_arch}" ] || cpu_arch="?"
[ -n "${cpu_arch}" ] || cpu_arch="General Processor"
case "$DISTRIB_TARGET" in
"x86"/*)

View File

View File

@ -7,25 +7,25 @@ THERMAL_PATH="/sys/class/thermal"
case "$DISTRIB_TARGET" in
ipq40xx/*|ipq806x/*)
wifi_temp="$(awk '{printf("%.1f°C ", $0 / 1000)}' "$IEEE_PATH"/phy*/device/hwmon/hwmon*/temp1_input 2>"/dev/null" | awk '$1=$1')"
wifi_temp="$(cat "$IEEE_PATH"/phy*/device/hwmon/hwmon*/temp1_input 2>"/dev/null" | awk '{printf("%.1f°C ", $0 / 1000)}' | awk '$1=$1')"
;;
mediatek/mt7622)
wifi_temp="$(awk '{printf("%.1f°C ", $0 / 1000)}' "$IEEE_PATH"/wl*/hwmon*/temp1_input 2>"/dev/null" | awk '$1=$1')"
wifi_temp="$(cat "$IEEE_PATH"/wl*/hwmon*/temp1_input 2>"/dev/null" | awk '{printf("%.1f°C ", $0 / 1000)}' | awk '$1=$1')"
;;
*)
wifi_temp="$(awk '{printf("%.1f°C ", $0 / 1000)}' "$IEEE_PATH"/phy*/hwmon*/temp1_input 2>"/dev/null" | awk '$1=$1')"
wifi_temp="$(cat "$IEEE_PATH"/phy*/hwmon*/temp1_input 2>"/dev/null" | awk '{printf("%.1f°C ", $0 / 1000)}' | awk '$1=$1')"
;;
esac
case "$DISTRIB_TARGET" in
ipq40xx/*)
if [ -e "$IEEE_PATH/phy0/hwmon0/temp1_input" ]; then
mt76_temp="$(awk -F ': ' '{print $2}' "$IEEE_PATH/phy0/hwmon0/temp1_input" 2>"/dev/null")°C"
mt76_temp="$(cat "$IEEE_PATH"/phy0/hwmon0/temp1_input 2>"/dev/null" | awk -F ': ' '{print $2}')°C"
fi
[ -z "$mt76_temp" ] || wifi_temp="${wifi_temp:+$wifi_temp }$mt76_temp"
;;
*)
cpu_temp="$(awk '{printf("%.1f°C", $0 / 1000)}' "$THERMAL_PATH/thermal_zone0/temp" 2>"/dev/null")"
cpu_temp="$(cat "$THERMAL_PATH"/thermal_zone0/temp 2>"/dev/null" | awk '{printf("%.1f°C", $0 / 1000)}')"
;;
esac

View File

@ -1,35 +0,0 @@
#
# Copyright (C) 2010-2011 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=autosamba
PKG_VERSION:=1
PKG_RELEASE:=12
include $(INCLUDE_DIR)/package.mk
define Package/autosamba
TITLE:=Samba autoconfig hotplug script.
MAINTAINER:=Lean
DEPENDS:=+luci-app-samba4 +wsdd2
PKGARCH:=all
endef
define Package/autosamba/description
A hotplug script to config Samba share automatically.
endef
define Build/Compile
endef
define Package/autosamba/install
$(INSTALL_DIR) $(1)/etc/hotplug.d/block
$(INSTALL_BIN) ./files/20-smb $(1)/etc/hotplug.d/block/
endef
$(eval $(call BuildPackage,autosamba))

View File

@ -1,106 +0,0 @@
#!/bin/sh
#
# D-Team Technology Co.,Ltd. ShenZhen
# 作者:Vic
#
# 警告:对着屏幕的哥们,我们允许你使用此脚本,但不允许你抹去作者的信息,请保留这段话。
#
. /lib/functions.sh
. /lib/functions/service.sh
global=0
config_file="/etc/config/samba4"
wait_for_init() {
for i in `seq 30`
do
[ -e /tmp/procd.done ] || {
sleep 1; continue;
}
return
done
}
smb_handle() {
config_get path $1 path
if [ "$path" = "$2" ] ;then
global=1
fi
}
chk_en() {
config_get_bool autoshare $1 autoshare 1
[ $autoshare -eq 0 ] && exit
}
config_load samba4
config_foreach chk_en samba4
device=`basename $DEVPATH`
case "$ACTION" in
add)
case "$device" in
sd*);;
md*);;
hd*);;
mmcblk*);;
*) return;;
esac
path="/dev/$device"
wait_for_init
cat /proc/mounts | grep -v '/boot\|/opt' | while read j
do
str=${j%% *}
if [ "$str" == $path ];then
strr=${j#* }
target=${strr%% *}
global=0
config_foreach smb_handle sambashare $target
name=${target#*/mnt/}
if [ $global -eq 0 ] ;then
echo -e "\n\nconfig sambashare" >> $config_file
echo -e "\toption auto '1'" >> $config_file
echo -e "\toption name '$name'" >> $config_file
echo -e "\toption path '$target'" >> $config_file
echo -e "\toption read_only 'no'" >> $config_file
echo -e "\toption guest_ok 'yes'" >> $config_file
echo -e "\toption create_mask '0666'" >> $config_file
echo -e "\toption dir_mask '0777'" >> $config_file
echo -e "\toption device '$device'" >> $config_file
echo -e "\toption inherit_owner 'yes'" >> $config_file
/etc/init.d/samba4 reload
return
fi
fi
done
;;
remove)
i=0
while true
do
dev=`uci get samba4.@sambashare[$i].device`
[ $? -ne 0 ] && break
[ "$dev" = "$device" ] && {
auto=`uci get samba4.@sambashare[$i].auto`
[ $auto = "1" ] && {
mount_dir=`uci get samba4.@sambashare[$i].name`
uci delete samba4.@sambashare[$i]
uci commit
/etc/init.d/samba4 reload
return
}
}
let i+=1
done
;;
esac

View File

@ -9,7 +9,7 @@ if ! uci -q get system.@imm_init[0].system_chn > "/dev/null"; then
delete system.ntp.server
add_list system.ntp.server="ntp.tencent.com"
add_list system.ntp.server="ntp1.aliyun.com"
add_list system.ntp.server="ntp.aliyun.com"
add_list system.ntp.server="ntp.ntsc.ac.cn"
add_list system.ntp.server="cn.ntp.org.cn"

View File

@ -0,0 +1,36 @@
# 忽略编译生成的文件
*.o
*.so
*.a
# LuCI 的生成文件和缓存
build/
bin/
.tmp/
# 忽略 OpenWrt 编译生成的安装包
*.ipk
*.tar.gz
*.deb
# 忽略临时文件和编辑器缓存
*.swp
*.swo
*.bak
*.tmp
*.log
.DS_Store
# 忽略 Git 操作时产生的临时文件
.git/
# IDE 配置文件
.vscode/
.idea/
# 忽略 Makefile 生成的中间文件
/feeds
/staging_dir
/tmp/
config.log
config.status

View File

@ -0,0 +1 @@
f8eeb311

View File

@ -0,0 +1,43 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=luci-app-athena-led
PKG_DEPENDS:=
PKG_VERSION:=0.0.7
PKG_RELEASE:=20241029
LUCI_TITLE:=LuCI Support for athena-led
LUCI_DEPENDS:=
include $(INCLUDE_DIR)/package.mk
# 包定义;指示我们的包将如何以及在哪里出现在整体配置菜单中 'make menuconfig'
define Package/$(PKG_NAME)
TITLE:=$(PKG_NAME)
endef
# Package description; a more verbose description on what our package does
define Package/$(PKG_NAME)/description
LuCI support for athenaLed
endef
define Package/$(PKG_NAME)/install
$(INSTALL_DIR) $(1)/usr/lib/lua/luci
cp -pR ./luasrc/* $(1)/usr/lib/lua/luci
$(INSTALL_DIR) $(1)/
cp -pR ./root/* $(1)/
endef
define Package/$(PKG_NAME)/postinst
#!/bin/sh
chmod +x /usr/sbin/athena-led
chmod +x /etc/init.d/athena_led
exit 0
endef
include $(TOPDIR)/feeds/luci/luci.mk
# This command is always the last, it uses the definitions and variables we give above in order to get the job done
$(eval $(call BuildPackage,$(PKG_NAME)))

View File

@ -0,0 +1,21 @@
# luci-app-athena-led
jdCloud ax6600 led screen ctrl
#### 定时关闭开启代码
```
# 早上9点30开启显示
30 9 * * * uci set athena_led.config.enable='1' && uci commit athena_led && /etc/init.d/athena_led reload
# 下午6点30关闭显示
30 18 * * * uci set athena_led.config.enable='0' && uci commit athena_led && /etc/init.d/athena_led reload
```
[推荐固件下载地址](https://github.com/VIKINGYFY/OpenWRT-CI/releases)
![image](https://github.com/user-attachments/assets/a2bcf6af-4e29-49d4-b183-799f68b74efb)
感谢以下朋友的捐赠
1. *姆

View File

@ -0,0 +1,18 @@
module("luci.controller.athena_led", package.seeall)
function index()
if not nixio.fs.access("/etc/config/athena_led") then
return
end
entry({ "admin", "system", "athena_led" }, firstchild(), _("Athena LED Ctrl"), 80).dependent = false
entry({ "admin", "system", "athena_led", "general" }, cbi("athena_led/settings"), _("Base Setting"), 1)
entry({ "admin", "system", "athena_led", "status" }, call("act_status"))
end
function act_status()
local e = {}
e.running = luci.sys.call("pgrep /usr/sbin/athena-led >/dev/null") == 0
luci.http.prepare_content("application/json")
luci.http.write_json(e)
end

View File

@ -0,0 +1,84 @@
m = Map("athena_led", translate("Athena led Ctrl"), translate("JDCloud AX6600 LED Screen Ctrl"))
m:section(SimpleSection).template = "athena_led/athena_led_status"
s = m:section(TypedSection, "athena_led")
s.addremove = false
s.anonymous = true
enable = s:option(Flag, "enable", translate("Enabled"))
enable.rmempty = false
seconds = s:option(ListValue, "seconds", translate("Display interval time"))
seconds.default = "5"
seconds.rmempty = false
seconds:value("1")
seconds:value("2")
seconds:value("3")
seconds:value("4")
seconds:value("5")
seconds.description = translate("Enable carousel display and set interval time in seconds")
seconds = s:option(ListValue, "lightLevel", translate("Display light level"))
seconds.default = "5"
seconds.rmempty = false
seconds:value("0")
seconds:value("1")
seconds:value("2")
seconds:value("3")
seconds:value("4")
seconds:value("5")
seconds:value("6")
seconds:value("7")
seconds.description = translate("Display light level desc")
status = s:option(MultiValue, "status", translate("side led status"))
status.default = ""
status.rmempty = true
status:value("time", translate("status time"))
status:value("medal", translate("status medal"))
status:value("upload", translate("status upload"))
status:value("download", translate("status download"))
status.description = translate("side led status desc")
type = s:option(MultiValue, "option", translate("Display Type"))
type.default = "date timeBlink"
type.rmempty = false
type:value("date", translate("Display Type Date"))
type:value("time", translate("Display Type Time"))
type:value("timeBlink", translate("Display Type Time Blink"))
type:value("temp", translate("Display Type temp"))
type:value("string", translate("Display Type String"))
type:value("getByUrl", translate("Display Type getByUrl"))
type.description = translate("Specify comma-separated values for option")
customValue = s:option(Value, "value", translate("Custom Value"))
customValue.default = "abcdefghijklmnopqrstuvwxyz0123456789+-*/=.::℃"
customValue.rmempty = false
customValue.placeholder = translate("Enter your message here")
customValue.description = translate("Set the custom message to display on the LED screen, Only effective on 'Display Type String'")
url = s:option(Value, "url", translate("api url for get content"))
url.default = "http://www.baidu.com"
url.rmempty = false
url.placeholder = translate("Enter your api url here")
url.description = translate("api url for get content des")
tempFlag = s:option(MultiValue, "tempFlag", translate("tempFlag"))
tempFlag.default = "4"
tempFlag.rmempty = false
tempFlag:value("0", translate("nss-top"))
tempFlag:value("1", translate("nss"))
tempFlag:value("2", translate("wcss-phya0"))
tempFlag:value("3", translate("wcss-phya1"))
tempFlag:value("4", translate("cpu"))
tempFlag:value("5", translate("lpass"))
tempFlag:value("6", translate("ddrss"))
tempFlag.description = translate("Set the item display on the LED screen, Only effective on 'Display Type temp'")
function m.on_after_commit(self)
local output = luci.util.exec("/etc/init.d/athena_led reload >/dev/null 2>&1")
luci.util.exec("logger '" .. output .. "'")
end
return m

View File

@ -0,0 +1,25 @@
<script type="text/javascript">//<![CDATA[
XHR.poll(3, '<%=url([[admin]], [[system]], [[athena_led]], [[status]])%>', null,
function (x, data) {
var tb = document.getElementById('athena_led_status');
if (data && tb) {
if (data.running) {
var links = '<em><b><font color=green>led <%:RUNNING%></font></b></em>';
tb.innerHTML = links;
} else {
tb.innerHTML = '<em><b><font color=red>led <%:NOT RUNNING%></font></b></em>';
}
}
}
);
//]]>
</script>
<style>.mar-10 {
margin-left: 50px;
margin-right: 10px;
}</style>
<fieldset class="cbi-section">
<p id="athena_led_status">
<em><%:Collecting data...%></em>
</p>
</fieldset>

View File

@ -0,0 +1,124 @@
msgid ""
msgstr "Content-Type: text/plain; charset=UTF-8"
msgid "athena_led"
msgstr "athena_led"
msgid "Base Setting"
msgstr "设置"
msgid "Gift"
msgstr "赞赏"
msgid "Athena LED Ctrl"
msgstr "雅典娜 LED 屏幕控制"
msgid "JDCloud AX6600 LED Screen Ctrl"
msgstr "京东云 AX6600 LED 屏幕控制"
msgid "Enabled"
msgstr "启用"
msgid "Display interval time"
msgstr "刷新时间"
msgid "Enable carousel display and set interval time in seconds"
msgstr "刷新时间"
msgid "Display light level"
msgstr "显示亮度调整"
msgid "Display light level desc"
msgstr "显示亮度调整,数字越大越亮"
msgid "side led status"
msgstr "侧边状态灯"
msgid "status time"
msgstr "时间"
msgid "status medal"
msgstr "奖牌"
msgid "status upload"
msgstr "上传"
msgid "status download"
msgstr "下载"
msgid "side led status desc"
msgstr "设置侧边状态灯"
msgid "Display Type"
msgstr "显示模式"
msgid "Display Type Date"
msgstr "日期"
msgid "Display Type Time"
msgstr "时间"
msgid "Display Type Time Blink"
msgstr "时间-闪烁"
msgid "Display Type temp"
msgstr "温度"
msgid "Display Type String"
msgstr "自定义文本"
msgid "Display Type getByUrl"
msgstr "远程文本"
msgid "Specify comma-separated values for option"
msgstr "显示模式"
msgid "Custom Value"
msgstr "自定义文本"
msgid "Enter your message here"
msgstr "输入你的自定义内容"
msgid "Set the custom message to display on the LED screen, Only effective on 'Display Type String'"
msgstr "设置显示在led屏幕上的自定义内容,选中'自定义文本'显示模式生效"
msgid "api url for get content"
msgstr "通过 http/get 请求获取显示内容"
msgid "Enter your api url here"
msgstr "在此处输入你的接口地址"
msgid "api url for get content des"
msgstr "通过 http/get 请求获取显示内容,选中'远程文本'显示模式生效"
msgid "All features are free, and tipping is just to buy me a coffee."
msgstr "所有功能都免费,打赏只是为了请我喝咖啡"
msgid "tempFlag"
msgstr "温度选项"
msgid "nss-top"
msgstr "网络子系统nss-top"
msgid "nss"
msgstr "网络子系统nss"
msgid "wcss-phya0"
msgstr "无线控制子系统-物理0"
msgid "wcss-phya1"
msgstr "无线控制子系统-物理1"
msgid "cpu"
msgstr "中央处理器cpu"
msgid "lpass"
msgstr "lpass"
msgid "ddrss"
msgstr "内存子系统ddr"
msgid "Set the item display on the LED screen, Only effective on 'Display Type temp'"
msgstr "设置显示在led屏幕上的温度,选中'温度'显示模式生效"

View File

@ -0,0 +1,124 @@
msgid ""
msgstr "Content-Type: text/plain; charset=UTF-8"
msgid "athena_led"
msgstr "athena_led"
msgid "Base Setting"
msgstr "设置"
msgid "Gift"
msgstr "赞赏"
msgid "Athena LED Ctrl"
msgstr "雅典娜 LED 屏幕控制"
msgid "JDCloud AX6600 LED Screen Ctrl"
msgstr "京东云 AX6600 LED 屏幕控制"
msgid "Enabled"
msgstr "启用"
msgid "Display interval time"
msgstr "刷新时间"
msgid "Enable carousel display and set interval time in seconds"
msgstr "刷新时间"
msgid "Display light level"
msgstr "显示亮度调整"
msgid "Display light level desc"
msgstr "显示亮度调整,数字越大越亮"
msgid "side led status"
msgstr "侧边状态灯"
msgid "status time"
msgstr "时间"
msgid "status medal"
msgstr "奖牌"
msgid "status upload"
msgstr "上传"
msgid "status download"
msgstr "下载"
msgid "side led status desc"
msgstr "设置侧边状态灯"
msgid "Display Type"
msgstr "显示模式"
msgid "Display Type Date"
msgstr "日期"
msgid "Display Type Time"
msgstr "时间"
msgid "Display Type Time Blink"
msgstr "时间-闪烁"
msgid "Display Type temp"
msgstr "温度"
msgid "Display Type String"
msgstr "自定义文本"
msgid "Display Type getByUrl"
msgstr "远程文本"
msgid "Specify comma-separated values for option"
msgstr "显示模式"
msgid "Custom Value"
msgstr "自定义文本"
msgid "Enter your message here"
msgstr "输入你的自定义内容"
msgid "Set the custom message to display on the LED screen, Only effective on 'Display Type String'"
msgstr "设置显示在led屏幕上的自定义内容,选中'自定义文本'显示模式生效"
msgid "api url for get content"
msgstr "通过 http/get 请求获取显示内容"
msgid "Enter your api url here"
msgstr "在此处输入你的接口地址"
msgid "api url for get content des"
msgstr "通过 http/get 请求获取显示内容,选中'远程文本'显示模式生效"
msgid "All features are free, and tipping is just to buy me a coffee."
msgstr "所有功能都免费,打赏只是为了请我喝咖啡"
msgid "tempFlag"
msgstr "温度选项"
msgid "nss-top"
msgstr "网络子系统nss-top"
msgid "nss"
msgstr "网络子系统nss"
msgid "wcss-phya0"
msgstr "无线控制子系统-物理0"
msgid "wcss-phya1"
msgstr "无线控制子系统-物理1"
msgid "cpu"
msgstr "中央处理器cpu"
msgid "lpass"
msgstr "lpass"
msgid "ddrss"
msgstr "内存子系统ddr"
msgid "Set the item display on the LED screen, Only effective on 'Display Type temp'"
msgstr "设置显示在led屏幕上的温度,选中'温度'显示模式生效"

View File

@ -0,0 +1,9 @@
config athena_led 'config'
option enable '1'
option status ' '
option seconds '5'
option lightLevel '5'
option option 'date timeBlink'
option value 'abcdefghijklmnopqrstuvwxyz0123456789+-*/=.::℃'
option url 'https://www.baidu.com'
option tempFlag '4'

View File

@ -0,0 +1,42 @@
#!/bin/sh /etc/rc.common
START=99
STOP=99
USE_PROCD=1
PROG=/usr/sbin/athena-led
start_service() {
config_load 'athena_led'
local cfg='config'
config_get_bool enabled "$cfg" 'enable' '0'
if [ "$enabled" -eq 0 ]; then
logger "athena-led Service is disabled, not starting"
return 1
fi
local status seconds lightLevel option value
config_get status $cfg 'status' ' '
config_get seconds $cfg 'seconds' '5'
config_get lightLevel $cfg 'lightLevel' '5'
config_get option $cfg 'option' 'date timeBlink'
config_get value $cfg 'value' 'abcdefghijklmnopqrstuvwxyz0123456789+-*/=.::℃'
config_get url $cfg 'url' 'https://www.baidu.com'
config_get tempFlag $cfg 'tempFlag' '4'
procd_open_instance
procd_set_param command $PROG -status "${status}" -seconds "${seconds}" -lightLevel "${lightLevel}" -option "${option}" -value "${value}" -url "${url}" -tempFlag "${tempFlag}"
procd_set_param respawn
procd_close_instance
}
service_triggers(){
procd_add_reload_trigger "athena_led"
}
reload_service()
{
stop
start
}

Binary file not shown.

View File

@ -8,13 +8,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=ath11k-firmware
PKG_SOURCE_DATE:=2024-10-14
PKG_SOURCE_VERSION:=15f050122da5ef5bef2cc8c7c19dfb7f98060a49
PKG_MIRROR_HASH:=e7a89d1570f32552ade539376181494724b5eafb31d00451ff2dcf5a2922a0cb
PKG_SOURCE_DATE:=2025-04-13
PKG_SOURCE_VERSION:=0353334f1ed0afdede3a3425350f90594b1ce323
PKG_MIRROR_HASH:=80cd9d1c8a96951d4e3a76802fdd711fa07d37d7c69459146be6c3b4ad5f97d9
PKG_RELEASE:=1
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://git.codelinaro.org/clo/ath-firmware/ath11k-firmware.git
PKG_SOURCE_URL:=https://github.com/VIKINGYFY/ath11k-firmware-ddwrt.git
PKG_LICENSE_FILES:=LICENSE.qca_firmware
@ -25,21 +25,6 @@ include $(INCLUDE_DIR)/package.mk
RSTRIP:=:
STRIP:=:
ATH11K_LEGACY_FW_NAME:=ath11k-legacy-firmware
ATH11K_LEGACY_FW_DATE:=2024-03-14
ATH11K_LEGACY_FW_RELEASE:=795809c7
ATH11K_LEGACY_FW_SUBDIR:=$(ATH11K_LEGACY_FW_NAME)-$(ATH11K_LEGACY_FW_DATE)~$(ATH11K_LEGACY_FW_RELEASE)
ATH11K_LEGACY_FW_SOURCE=$(ATH11K_LEGACY_FW_SUBDIR).tar.zst
define Download/$(ATH11K_LEGACY_FW_NAME)
FILE:=$(ATH11K_LEGACY_FW_SOURCE)
PROTO:=git
URL:=https://github.com/quic/upstream-wifi-fw.git
SOURCE_VERSION:=795809c7041582bd51bdfaa1f548b916ae8d4382
MIRROR_HASH:=e042024b6762a5b4fe56f1a5bf8870df2e7abcca90ec22103cd46a609bee7cec
SUBDIR:=$(ATH11K_LEGACY_FW_SUBDIR)
endef
define Package/ath11k-firmware-default
SECTION:=firmware
CATEGORY:=Firmware
@ -73,60 +58,33 @@ $(Package/ath11k-firmware-default)
TITLE:=QCN9074 ath11k firmware
endef
define Build/Clean
$(call Build/Clean/Default,)
rm -rf \
$(BUILD_DIR)/$(ATH11K_LEGACY_FW_SUBDIR)
endef
define Build/Prepare
$(eval $(call Download,ath11k-legacy-firmware))
$(call Build/Prepare/Default,)
$(TAR) -C $(BUILD_DIR) -xf $(DL_DIR)/$(ATH11K_LEGACY_FW_SOURCE)
endef
define Build/Compile
endef
define Package/ath11k-firmware-ipq5018/install
$(INSTALL_DIR) $(1)/lib/firmware/ath11k/IPQ5018/hw1.0
$(INSTALL_DATA) \
$(BUILD_DIR)/$(ATH11K_LEGACY_FW_SUBDIR)/ath11k-firmware/IPQ5018_QCN6122_QCN6122/hw1.0/2.7.0.1/WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1/*.* \
$(1)/lib/firmware/ath11k/IPQ5018/hw1.0/
$(INSTALL_DATA) $(PKG_BUILD_DIR)/IPQ5018/hw1.0/* $(1)/lib/firmware/ath11k/IPQ5018/hw1.0/
endef
define Package/ath11k-firmware-ipq6018/install
$(INSTALL_DIR) $(1)/lib/firmware/IPQ6018
$(INSTALL_DATA) \
$(PKG_BUILD_DIR)/IPQ6018/hw1.0/2.5.0.1/WLAN.HK.2.5.0.1-03982-QCAHKSWPL_SILICONZ-3/* \
$(1)/lib/firmware/IPQ6018/
$(INSTALL_DATA) $(PKG_BUILD_DIR)/IPQ6018/hw1.0/* $(1)/lib/firmware/IPQ6018/
endef
define Package/ath11k-firmware-ipq8074/install
$(INSTALL_DIR) $(1)/lib/firmware/IPQ8074
$(INSTALL_DATA) \
$(PKG_BUILD_DIR)/IPQ8074/hw2.0/2.9.0.1/WLAN.HK.2.9.0.1-02146-QCAHKSWPL_SILICONZ-1/* \
$(1)/lib/firmware/IPQ8074/
$(INSTALL_DATA) $(PKG_BUILD_DIR)/IPQ8074/hw2.0/* $(1)/lib/firmware/IPQ8074/
endef
define Package/ath11k-firmware-qcn6122/install
$(INSTALL_DIR) $(1)/lib/firmware/ath11k/QCN6122/hw1.0
$(INSTALL_DATA) \
$(BUILD_DIR)/$(ATH11K_LEGACY_FW_SUBDIR)/ath11k-firmware/IPQ5018_QCN6122_QCN6122/hw1.0/2.7.0.1/WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1/qcn6122/* \
$(1)/lib/firmware/ath11k/QCN6122/hw1.0/
$(INSTALL_DATA) $(PKG_BUILD_DIR)/QCN6122/hw1.0/* $(1)/lib/firmware/ath11k/QCN6122/hw1.0/
endef
define Package/ath11k-firmware-qcn9074/install
$(INSTALL_DIR) $(1)/lib/firmware/ath11k/QCN9074/hw1.0
$(INSTALL_DATA) \
$(PKG_BUILD_DIR)/QCN9074/hw1.0/2.9.0.1/WLAN.HK.2.9.0.1-02146-QCAHKSWPL_SILICONZ-1/* \
$(1)/lib/firmware/ath11k/QCN9074/hw1.0/
$(INSTALL_BIN) \
$(PKG_BUILD_DIR)/QCN9074/hw1.0/board-2.bin $(1)/lib/firmware/ath11k/QCN9074/hw1.0/board-2.bin
$(INSTALL_DATA) $(PKG_BUILD_DIR)/QCN9074/hw1.0/* $(1)/lib/firmware/ath11k/QCN9074/hw1.0/
endef
$(eval $(call BuildPackage,ath11k-firmware-ipq5018))

View File

@ -6,9 +6,9 @@ PKG_RELEASE:=1
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL=$(PROJECT_GIT)/project/firmware/qca-wireless.git
PKG_SOURCE_DATE:=2025-04-01
PKG_SOURCE_VERSION:=c220fac7fdb35628ba53ff53ed36cf883a401161
PKG_MIRROR_HASH:=26338b4f165eb2e90273cd61ed26715b99e496ccf738167e22ff9213ca42c973
PKG_SOURCE_DATE:=2025-04-15
PKG_SOURCE_VERSION:=38a18dc26c9b150f06f56b9c5972d789eb5bc0c4
PKG_MIRROR_HASH:=a10a9b524ecd91854265b04819303410ae77e1f5a093f9cc8eb43e25e99c1bae
PKG_FLAGS:=nonshared
include $(INCLUDE_DIR)/package.mk
@ -66,8 +66,9 @@ ALLWIFIBOARDS:= \
redmi_ax6 \
skspruce_wia3300-20 \
spectrum_sax1v1k \
tplink_eap610-outdoor \
tplink_eap610od \
tplink_eap620hd-v1 \
tplink_eap623od-hd-v1 \
tplink_eap660hd-v1 \
wallys_dr40x9 \
xiaomi_ax3600 \
@ -81,7 +82,17 @@ ALLWIFIBOARDS:= \
zte_mf286c \
zte_mf287 \
zte_mf287plus \
zyxel_nbg7815
zyxel_nbg7815 \
cmiot_ax18 \
jdcloud_re-ss-01 \
jdcloud_re-cs-02 \
jdcloud_re-cs-03 \
link_nn6000 \
redmi_ax5 \
redmi_ax5-jdcloud \
verizon_cr1000a \
xiaomi_ax1800 \
zn_m2
ALLWIFIPACKAGES:=$(foreach BOARD,$(ALLWIFIBOARDS),ipq-wifi-$(BOARD))
@ -214,8 +225,9 @@ $(eval $(call generate-ipq-wifi-package,prpl_haze,prpl Haze))
$(eval $(call generate-ipq-wifi-package,redmi_ax6,Redmi AX6))
$(eval $(call generate-ipq-wifi-package,skspruce_wia3300-20,SKSpruce WIA3300-20))
$(eval $(call generate-ipq-wifi-package,spectrum_sax1v1k,Spectrum SAX1V1K))
$(eval $(call generate-ipq-wifi-package,tplink_eap610-outdoor,TPLink EAP610-Outdoor))
$(eval $(call generate-ipq-wifi-package,tplink_eap610od,TPLink EAP610-Outdoor))
$(eval $(call generate-ipq-wifi-package,tplink_eap620hd-v1,TP-Link EAP620 HD v1))
$(eval $(call generate-ipq-wifi-package,tplink_eap623od-hd-v1,TP-Link EAP623-Outdoor HD v1))
$(eval $(call generate-ipq-wifi-package,tplink_eap660hd-v1,TP-Link EAP660 HD v1))
$(eval $(call generate-ipq-wifi-package,wallys_dr40x9,Wallys DR40X9))
$(eval $(call generate-ipq-wifi-package,xiaomi_ax3600,Xiaomi AX3600))
@ -230,5 +242,15 @@ $(eval $(call generate-ipq-wifi-package,zte_mf286c,ZTE MF286C))
$(eval $(call generate-ipq-wifi-package,zte_mf287,ZTE MF287))
$(eval $(call generate-ipq-wifi-package,zte_mf287plus,ZTE MF287Plus))
$(eval $(call generate-ipq-wifi-package,zyxel_nbg7815,Zyxel NBG7815))
$(eval $(call generate-ipq-wifi-package,cmiot_ax18,CMIOT AX18))
$(eval $(call generate-ipq-wifi-package,jdcloud_re-ss-01,JDCloud RE-SS-01))
$(eval $(call generate-ipq-wifi-package,jdcloud_re-cs-02,JDCloud RE-CS-02))
$(eval $(call generate-ipq-wifi-package,jdcloud_re-cs-03,JDCloud RE-CS-03))
$(eval $(call generate-ipq-wifi-package,link_nn6000,Link NN6000))
$(eval $(call generate-ipq-wifi-package,redmi_ax5,Redmi AX5))
$(eval $(call generate-ipq-wifi-package,redmi_ax5-jdcloud,Redmi AX5 JDCloud))
$(eval $(call generate-ipq-wifi-package,verizon_cr1000a,Verizon CR1000A))
$(eval $(call generate-ipq-wifi-package,xiaomi_ax1800,Xiaomi AX1800))
$(eval $(call generate-ipq-wifi-package,zn_m2,ZN M2))
$(foreach PACKAGE,$(ALLWIFIPACKAGES),$(eval $(call BuildPackage,$(PACKAGE))))

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -25,6 +25,8 @@ define Package/layerscape-fman
CATEGORY:=Firmware
TITLE:=NXP FMan ucode
DEPENDS:=@TARGET_layerscape
DEFAULT:=y if TARGET_layerscape_armv8_64b
HIDDEN:=1
endef
define Build/Compile

View File

@ -27,6 +27,8 @@ define Package/layerscape-ddr-phy
CATEGORY:=Firmware
TITLE:=NXP Layerscape DDR PHY firmware
DEPENDS:=@TARGET_layerscape
DEFAULT:=y if TARGET_layerscape_armv8_64b
HIDDEN:=1
endef
define Build/Compile

View File

@ -26,6 +26,8 @@ define Package/layerscape-dpl
CATEGORY:=Firmware
TITLE:=NXP DPL firmware
DEPENDS:=@TARGET_layerscape
DEFAULT:=y if TARGET_layerscape_armv8_64b
HIDDEN:=1
endef
MAKE_PATH:=config

View File

@ -25,6 +25,8 @@ define Package/layerscape-mc
CATEGORY:=Firmware
TITLE:=NXP MC firmware
DEPENDS:=@TARGET_layerscape
DEFAULT:=y if TARGET_layerscape_armv8_64b
HIDDEN:=1
endef
define Build/Compile

View File

@ -25,6 +25,8 @@ define Package/layerscape-rcw
CATEGORY:=Firmware
TITLE:=NXP Layerscape RCW binaries
DEPENDS:=@TARGET_layerscape
DEFAULT:=y if TARGET_layerscape_armv7
HIDDEN:=1
endef
BOARDS := \

View File

@ -5,3 +5,11 @@ define Package/ath12k-firmware-wcn7850/install
$(PKG_BUILD_DIR)/ath12k/WCN7850/hw2.0/* $(1)/lib/firmware/ath12k/WCN7850/hw2.0/
endef
$(eval $(call BuildPackage,ath12k-firmware-wcn7850))
Package/ath12k-firmware-qcn9274 = $(call Package/firmware-default,QCN9274 ath12k firmware)
define Package/ath12k-firmware-qcn9274/install
$(INSTALL_DIR) $(1)/lib/firmware/ath12k/QCN9274/hw2.0
$(INSTALL_DATA) \
$(PKG_BUILD_DIR)/ath12k/QCN9274/hw2.0/* $(1)/lib/firmware/ath12k/QCN9274/hw2.0/
endef
$(eval $(call BuildPackage,ath12k-firmware-qcn9274))

View File

@ -7,8 +7,7 @@ Rollback some APIs to fix compilation errors.
Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
---
ath10k-6.14/ahb.c | 2 +-
ath10k-6.14/mac.c | 5 ++---
2 files changed, 3 insertions(+), 4 deletions(-)
1 files changed, 1 insertions(+), 1 deletions(-)
--- a/ath10k-6.14/ahb.c
+++ b/ath10k-6.14/ahb.c
@ -21,26 +20,3 @@ Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
};
int ath10k_ahb_init(void)
--- a/ath10k-6.14/mac.c
+++ b/ath10k-6.14/mac.c
@@ -9607,10 +9607,9 @@ exit:
static void ath10k_sta_rc_update(struct ieee80211_hw *hw,
struct ieee80211_vif *vif,
- struct ieee80211_link_sta *link_sta,
+ struct ieee80211_sta *sta,
u32 changed)
{
- struct ieee80211_sta *sta = link_sta->sta;
struct ath10k *ar = hw->priv;
struct ath10k_sta *arsta = (struct ath10k_sta *)sta->drv_priv;
struct ath10k_vif *arvif = (void *)vif->drv_priv;
@@ -10603,7 +10602,7 @@ static const struct ieee80211_ops ath10k
.reconfig_complete = ath10k_reconfig_complete,
.get_survey = ath10k_get_survey,
.set_bitrate_mask = ath10k_mac_op_set_bitrate_mask,
- .link_sta_rc_update = ath10k_sta_rc_update,
+ .sta_rc_update = ath10k_sta_rc_update,
.offset_tsf = ath10k_offset_tsf,
.get_tsf = ath10k_get_tsf,
.ampdu_action = ath10k_ampdu_action,

View File

@ -0,0 +1,20 @@
--- a/ath10k-6.10/mac.c
+++ b/ath10k-6.10/mac.c
@@ -6365,7 +6365,7 @@ static int ath10k_mac_set_txbf_conf(stru
ar->wmi.vdev_param->txbf, value);
}
-static void ath10k_update_vif_offload(struct ieee80211_hw *hw,
+static int ath10k_update_vif_offload(struct ieee80211_hw *hw,
struct ieee80211_vif *vif)
{
struct ath10k_vif *arvif = (void *)vif->drv_priv;
@@ -6387,6 +6387,8 @@ static void ath10k_update_vif_offload(st
ath10k_warn(ar, "failed to set vdev %i TX encapsulation: %d\n",
arvif->vdev_id, ret);
}
+
+ return ret;
}
/*

View File

@ -0,0 +1,33 @@
--- a/ath10k-6.10/pci.c
+++ b/ath10k-6.10/pci.c
@@ -2285,6 +2285,7 @@ static int ath10k_pci_hif_start(struct a
ath10k_dbg(ar, ATH10K_DBG_BOOT, "boot hif start\n");
+ dev_set_threaded(ar->napi_dev, true);
ath10k_core_napi_enable(ar);
ath10k_pci_irq_enable(ar);
--- a/ath10k-6.10/sdio.c
+++ b/ath10k-6.10/sdio.c
@@ -1863,6 +1863,7 @@ static int ath10k_sdio_hif_start(struct
struct ath10k_sdio *ar_sdio = ath10k_sdio_priv(ar);
int ret;
+ dev_set_threaded(&ar->napi_dev, true);
ath10k_core_napi_enable(ar);
/* Sleep 20 ms before HIF interrupts are disabled.
--- a/ath10k-6.10/core.c
+++ b/ath10k-6.10/core.c
@@ -4576,6 +4576,10 @@ struct ath10k *ath10k_core_create(size_t
if (!ar->napi_dev)
goto err_free_tx_complete;
+ snprintf(ar->napi_dev->name, sizeof(ar->napi_dev->name), "ath10k_%s",
+ wiphy_name(ar->hw->wiphy));
+ dev_set_threaded(ar->napi_dev, true);
+
ret = ath10k_coredump_create(ar);
if (ret)
goto err_free_netdev;

View File

@ -35,9 +35,9 @@ define Package/bcm63xx-cfe/install
endef
define Build/InstallDev
rm -rf $(KERNEL_BUILD_DIR)/$(PKG_NAME)
mkdir -p $(KERNEL_BUILD_DIR)/$(PKG_NAME)
$(CP) -r $(PKG_BUILD_DIR)/* $(KERNEL_BUILD_DIR)/$(PKG_NAME)
rm -rf $(STAGING_DIR_IMAGE)/$(PKG_NAME)
mkdir -p $(STAGING_DIR_IMAGE)/$(PKG_NAME)
$(CP) -r $(PKG_BUILD_DIR)/* $(STAGING_DIR_IMAGE)/$(PKG_NAME)
endef
$(eval $(call BuildPackage,bcm63xx-cfe))

View File

@ -41,13 +41,22 @@ define KernelPackage/cryptodev/description
via a "/dev/crypto" device.
endef
ifneq ($(CONFIG_PACKAGE_kmod-crypto-qce),)
EXTRA_CFLAGS+=-DQCA
endif
ifneq ($(CONFIG_PACKAGE_kmod-qca-nss-crypto),)
EXTRA_CFLAGS+=-DQCANSS
endif
define Build/Configure
endef
define Build/Compile
$(MAKE) -C $(PKG_BUILD_DIR) \
$(KERNEL_MAKE_FLAGS) \
KERNEL_DIR="$(LINUX_DIR)"
KERNEL_DIR="$(LINUX_DIR)" \
EXTRA_CFLAGS="$(EXTRA_CFLAGS)"
endef
define Build/InstallDev

View File

@ -0,0 +1,99 @@
--- a/ioctl.c
+++ b/ioctl.c
@@ -829,29 +829,37 @@ static inline void tfm_info_to_alg_info(
"%s", crypto_tfm_alg_driver_name(tfm));
}
-#ifndef CRYPTO_ALG_KERN_DRIVER_ONLY
+#if defined(QCANSS) || defined(QCA) || defined(MT7621) || defined(MT7622) || defined(LANTIQ) || defined(BCM675X) || defined(BCM49XX) || defined(MT798X)
static unsigned int is_known_accelerated(struct crypto_tfm *tfm)
{
const char *name = crypto_tfm_alg_driver_name(tfm);
if (name == NULL)
- return 1; /* assume accelerated */
+ return 0;
/* look for known crypto engine names */
- if (strstr(name, "-talitos") ||
- !strncmp(name, "mv-", 3) ||
- !strncmp(name, "atmel-", 6) ||
- strstr(name, "geode") ||
- strstr(name, "hifn") ||
- strstr(name, "-ixp4xx") ||
- strstr(name, "-omap") ||
- strstr(name, "-picoxcell") ||
- strstr(name, "-s5p") ||
- strstr(name, "-ppc4xx") ||
- strstr(name, "-caam") ||
- strstr(name, "-n2"))
+#if defined(QCANSS)
+ if (!strncmp(name, "nss-", 4))
return 1;
-
+#elif defined(QCA)
+ if (!strncmp(name, "qcrypto", 7))
+ return 1;
+#elif defined(MT7621)
+ if (strstr(name, "eip93"))
+ return 1;
+#elif defined(MT7622)
+ if (strstr(name, "mtk"))
+ return 1;
+#elif defined(MT798X)
+ if (strstr(name, "safexcel-"))
+ return 1;
+#elif defined(LANTIQ)
+ if (strstr(name, "ltq-crypto"))
+ return 1;
+#elif defined(BCM675X) || defined(BCM49XX)
+ if (strstr(name, "-iproc"))
+ return 1;
+#endif
return 0;
}
#endif
@@ -876,22 +884,22 @@ static int get_session_info(struct fcryp
else
tfm = crypto_aead_tfm(ses_ptr->cdata.async.as);
tfm_info_to_alg_info(&siop->cipher_info, tfm);
-#ifdef CRYPTO_ALG_KERN_DRIVER_ONLY
- if (tfm->__crt_alg->cra_flags & CRYPTO_ALG_KERN_DRIVER_ONLY)
+#if defined(QCANSS) || defined(QCA) || defined(MT7621) || defined(MT7622) || defined(LANTIQ) || defined(BCM675X) || defined(BCM49XX) || defined(MT798X)
+ if (is_known_accelerated(tfm))
siop->flags |= SIOP_FLAG_KERNEL_DRIVER_ONLY;
#else
- if (is_known_accelerated(tfm))
+ if (tfm->__crt_alg->cra_flags & CRYPTO_ALG_KERN_DRIVER_ONLY)
siop->flags |= SIOP_FLAG_KERNEL_DRIVER_ONLY;
#endif
}
if (ses_ptr->hdata.init) {
tfm = crypto_ahash_tfm(ses_ptr->hdata.async.s);
tfm_info_to_alg_info(&siop->hash_info, tfm);
-#ifdef CRYPTO_ALG_KERN_DRIVER_ONLY
- if (tfm->__crt_alg->cra_flags & CRYPTO_ALG_KERN_DRIVER_ONLY)
+#if defined(QCANSS) || defined(QCA) || defined(MT7621) || defined(MT7622) || defined(LANTIQ) || defined(BCM675X) || defined(BCM49XX) || defined(MT798X)
+ if (is_known_accelerated(tfm))
siop->flags |= SIOP_FLAG_KERNEL_DRIVER_ONLY;
#else
- if (is_known_accelerated(tfm))
+ if (tfm->__crt_alg->cra_flags & CRYPTO_ALG_KERN_DRIVER_ONLY)
siop->flags |= SIOP_FLAG_KERNEL_DRIVER_ONLY;
#endif
}
--- a/main.c
+++ b/main.c
@@ -168,6 +168,12 @@ __crypto_run_zc(struct csession *ses_ptr
struct crypt_op *cop = &kcop->cop;
int ret = 0;
+#if defined(QCANSS)
+//openssl bug!!!
+ if (unlikely(cop->src != cop->dst)) {
+ return __crypto_run_std(ses_ptr, cop);
+ }
+#endif
ret = get_userbuf(ses_ptr, cop->src, cop->len, cop->dst, cop->len,
kcop->task, kcop->mm, &src_sg, &dst_sg);
if (unlikely(ret)) {

View File

@ -674,7 +674,7 @@ static void gpio_keys_irq_close(struct gpio_keys_button_dev *bdev)
}
}
static int gpio_keys_remove(struct platform_device *pdev)
static void gpio_keys_remove(struct platform_device *pdev)
{
struct gpio_keys_button_dev *bdev = platform_get_drvdata(pdev);
@ -684,13 +684,11 @@ static int gpio_keys_remove(struct platform_device *pdev)
gpio_keys_polled_close(bdev);
else
gpio_keys_irq_close(bdev);
return 0;
}
static struct platform_driver gpio_keys_driver = {
.probe = gpio_keys_probe,
.remove = gpio_keys_remove,
.remove_new = gpio_keys_remove,
.driver = {
.name = "gpio-keys",
.of_match_table = of_match_ptr(gpio_keys_of_match),
@ -699,7 +697,7 @@ static struct platform_driver gpio_keys_driver = {
static struct platform_driver gpio_keys_polled_driver = {
.probe = gpio_keys_polled_probe,
.remove = gpio_keys_remove,
.remove_new = gpio_keys_remove,
.driver = {
.name = "gpio-keys-polled",
.of_match_table = of_match_ptr(gpio_keys_polled_of_match),

View File

@ -2780,7 +2780,7 @@ static int ltq_mei_probe(struct platform_device *pdev)
return 0;
}
static int ltq_mei_remove(struct platform_device *pdev)
static void ltq_mei_remove(struct platform_device *pdev)
{
int i = 0;
int num;
@ -2794,7 +2794,6 @@ static int ltq_mei_remove(struct platform_device *pdev)
IFX_MEI_ExitDevice (i);
}
}
return 0;
}
static const struct of_device_id ltq_mei_match[] = {
@ -2804,7 +2803,7 @@ static const struct of_device_id ltq_mei_match[] = {
static struct platform_driver ltq_mei_driver = {
.probe = ltq_mei_probe,
.remove = ltq_mei_remove,
.remove_new = ltq_mei_remove,
.driver = {
.name = "lantiq,mei-xway",
.of_match_table = ltq_mei_match,

View File

@ -1865,7 +1865,7 @@ INIT_PRIV_DATA_FAIL:
return ret;
}
static int ltq_atm_remove(struct platform_device *pdev)
static void ltq_atm_remove(struct platform_device *pdev)
{
int port_num;
struct ltq_atm_ops *ops = platform_get_drvdata(pdev);
@ -1885,13 +1885,11 @@ static int ltq_atm_remove(struct platform_device *pdev)
ops->shutdown();
clear_priv_data();
return 0;
}
static struct platform_driver ltq_atm_driver = {
.probe = ltq_atm_probe,
.remove = ltq_atm_remove,
.remove_new = ltq_atm_remove,
.driver = {
.name = "atm",
.of_match_table = ltq_atm_match,

View File

@ -143,7 +143,7 @@ static int ltq_deu_probe(struct platform_device *pdev)
* \ingroup IFX_DEU_FUNCTIONS
* \brief remove the loaded crypto algorithms
*/
static int ltq_deu_remove(struct platform_device *pdev)
static void ltq_deu_remove(struct platform_device *pdev)
{
//#ifdef CONFIG_CRYPTO_DEV_PWR_SAVE_MODE
#if defined(CONFIG_CRYPTO_DEV_DES)
@ -168,8 +168,6 @@ static int ltq_deu_remove(struct platform_device *pdev)
ifxdeu_fini_md5_hmac ();
#endif
printk("DEU has exited successfully\n");
return 0;
}
@ -193,7 +191,7 @@ MODULE_DEVICE_TABLE(of, ltq_deu_match);
static struct platform_driver ltq_deu_driver = {
.probe = ltq_deu_probe,
.remove = ltq_deu_remove,
.remove_new = ltq_deu_remove,
.driver = {
.name = "deu",
.of_match_table = ltq_deu_match,

View File

@ -1566,7 +1566,7 @@ INIT_PRIV_DATA_FAIL:
* Output:
* none
*/
static int ltq_ptm_remove(struct platform_device *pdev)
static void ltq_ptm_remove(struct platform_device *pdev)
{
int i;
@ -1591,13 +1591,11 @@ static int ltq_ptm_remove(struct platform_device *pdev)
ifx_ptm_uninit_chip();
clear_priv_data();
return 0;
}
static struct platform_driver ltq_ptm_driver = {
.probe = ltq_ptm_probe,
.remove = ltq_ptm_remove,
.remove_new = ltq_ptm_remove,
.driver = {
.name = "ptm",
.of_match_table = ltq_ptm_match,

View File

@ -1079,7 +1079,7 @@ INIT_PRIV_DATA_FAIL:
return ret;
}
static int ltq_ptm_remove(struct platform_device *pdev)
static void ltq_ptm_remove(struct platform_device *pdev)
{
int i;
ifx_mei_atm_showtime_enter = NULL;
@ -1103,8 +1103,6 @@ static int ltq_ptm_remove(struct platform_device *pdev)
ifx_ptm_uninit_chip();
clear_priv_data();
return 0;
}
#ifndef MODULE
@ -1135,7 +1133,7 @@ static int __init queue_gamma_map_setup(char *line)
#endif
static struct platform_driver ltq_ptm_driver = {
.probe = ltq_ptm_probe,
.remove = ltq_ptm_remove,
.remove_new = ltq_ptm_remove,
.driver = {
.name = "ptm",
.of_match_table = ltq_ptm_match,

View File

@ -3,6 +3,7 @@
net.netfilter.nf_conntrack_acct=1
net.netfilter.nf_conntrack_checksum=0
net.netfilter.nf_conntrack_max=65535
net.netfilter.nf_conntrack_tcp_timeout_established=7440
net.netfilter.nf_conntrack_udp_timeout=60
net.netfilter.nf_conntrack_udp_timeout_stream=180

View File

@ -1193,7 +1193,6 @@ endef
$(eval $(call KernelPackage,crypto-xts))
define KernelPackage/crypto-xxhash
TITLE:=xxHash non-cryptographic hash algorithm
DEPENDS:=+kmod-crypto-hash +kmod-lib-xxhash
@ -1205,3 +1204,20 @@ endef
$(eval $(call KernelPackage,crypto-xxhash))
define KernelPackage/crypto-qce
TITLE:=QTI Crypto Engine (QCE)
KCONFIG:= \
CONFIG_CRYPTO_DEV_QCE \
CONFIG_CRYPTO_DEV_QCE_AEAD=y \
CONFIG_CRYPTO_DEV_QCE_ENABLE_ALL=y \
CONFIG_CRYPTO_DEV_QCE_SHA=y \
CONFIG_CRYPTO_DEV_QCE_SKCIPHER=y \
CONFIG_CRYPTO_DEV_QCE_SW_MAX_LEN=512
FILES:= \
$(LINUX_DIR)/drivers/crypto/qce/qcrypto.ko
AUTOLOAD:=$(call AutoLoad,09,qcrypto)
DEPENDS:=@TARGET_qualcommax +kmod-crypto-manager +kmod-crypto-hash +kmod-crypto-des
$(call AddDepends/crypto)
endef
$(eval $(call KernelPackage,crypto-qce))

View File

@ -658,7 +658,7 @@ $(eval $(call KernelPackage,dsa-realtek))
define KernelPackage/dsa-rtl8366rb
SUBMENU:=$(NETWORK_DEVICES_MENU)
TITLE:=Realtek RTL8365MB switch DSA support
TITLE:=Realtek RTL8366RB switch DSA support
DEPENDS:=+kmod-dsa-realtek @!TARGET_x86 @!TARGET_bcm47xx @!TARGET_uml
KCONFIG:= \
CONFIG_NET_DSA_REALTEK_RTL8366RB \

View File

@ -328,6 +328,7 @@ $(eval $(call KernelPackage,ipt-offload))
define KernelPackage/ipt-ipopt
TITLE:=Modules for matching/changing IP packet options
KCONFIG:=$(KCONFIG_IPT_IPOPT)
DEPENDS:=+PACKAGE_kmod-nf-conntrack:kmod-nf-conntrack
FILES:=$(foreach mod,$(IPT_IPOPT-m),$(LINUX_DIR)/net/$(mod).ko)
AUTOLOAD:=$(call AutoProbe,$(notdir $(IPT_IPOPT-m)))
$(call AddDepends/ipt)

View File

@ -1651,6 +1651,7 @@ endef
$(eval $(call KernelPackage,qrtr-mhi))
define KernelPackage/unix-diag
SUBMENU:=$(NETWORK_SUPPORT_MENU)
TITLE:=UNIX socket monitoring interface
KCONFIG:=CONFIG_UNIX_DIAG
FILES:= $(LINUX_DIR)/net/unix/unix_diag.ko
@ -1660,6 +1661,7 @@ endef
$(eval $(call KernelPackage,unix-diag))
define KernelPackage/packet-diag
SUBMENU:=$(NETWORK_SUPPORT_MENU)
TITLE:=Packet sockets monitoring interface
KCONFIG:=CONFIG_PACKET_DIAG
FILES:= $(LINUX_DIR)/net/packet/af_packet_diag.ko

View File

@ -538,7 +538,7 @@ $(eval $(call KernelPackage,usb-dwc3-octeon))
define KernelPackage/usb-dwc3-qcom
TITLE:=DWC3 Qualcomm USB driver
DEPENDS:=@(TARGET_ipq40xx||TARGET_ipq806x||TARGET_qualcommax) +kmod-usb-dwc3
DEPENDS:=@(TARGET_ipq40xx||TARGET_ipq806x||TARGET_qualcommax||TARGET_qualcommbe) +kmod-usb-dwc3
KCONFIG:= CONFIG_USB_DWC3_QCOM
FILES:= $(LINUX_DIR)/drivers/usb/dwc3/dwc3-qcom.ko
AUTOLOAD:=$(call AutoLoad,53,dwc3-qcom,1)

View File

@ -36,14 +36,21 @@ PKG_CONFIG_DEPENDS:= \
CONFIG_PACKAGE_MAC80211_DEBUGFS \
CONFIG_PACKAGE_MAC80211_MESH \
CONFIG_PACKAGE_MAC80211_TRACING \
CONFIG_PACKAGE_MAC80211_NSS_SUPPORT \
CONFIG_PACKAGE_MAC80211_NSS_REDIRECT \
CONFIG_PACKAGE_IWLWIFI_DEBUG \
CONFIG_PACKAGE_IWLWIFI_DEBUGFS \
CONFIG_PACKAGE_RTLWIFI_DEBUG \
CONFIG_PACKAGE_RTLWIFI_DEBUG
include $(INCLUDE_DIR)/package.mk
WMENU:=Wireless Drivers
NSS_PATCH:= subsys ath10k ath11k
IPQ_BRANCH:=$(shell git -C $(TOPDIR) rev-parse --abbrev-ref HEAD)
IPQ_DATE:=$(shell git -C $(TOPDIR) log -1 --format=%cd --date=format:%Y-%m-%d)
IPQ_COMMIT:=$(shell git -C $(TOPDIR) log -1 --format=%h)
define KernelPackage/mac80211/Default
SUBMENU:=$(WMENU)
URL:=https://wireless.wiki.kernel.org/
@ -129,10 +136,15 @@ define KernelPackage/mac80211
$(call KernelPackage/mac80211/Default)
TITLE:=Linux 802.11 Wireless Networking Stack
# +kmod-crypto-cmac is a runtime only dependency of net/mac80211/aes_cmac.c
DEPENDS+= +kmod-cfg80211 +kmod-crypto-cmac +kmod-crypto-ccm +kmod-crypto-gcm +hostapd-common
DEPENDS+= +kmod-cfg80211 +kmod-crypto-cmac +kmod-crypto-ccm +kmod-crypto-gcm +hostapd-common \
+ATH11K_NSS_SUPPORT:kmod-qca-nss-drv
KCONFIG:=\
CONFIG_AVERAGE=y
FILES:= $(PKG_BUILD_DIR)/net/mac80211/mac80211.ko
ifdef CONFIG_PACKAGE_MAC80211_NSS_REDIRECT
AUTOLOAD:=$(call AutoProbe, mac80211)
MODPARAMS.mac80211:=nss_redirect=1
endif
ABI_VERSION:=$(PKG_VERSION)-$(PKG_RELEASE)
MENU:=1
endef
@ -140,6 +152,21 @@ endef
define KernelPackage/mac80211/config
if PACKAGE_kmod-mac80211
if PACKAGE_kmod-qca-nss-drv
config PACKAGE_MAC80211_NSS_SUPPORT
bool "Enable NSS support"
default y
help
This option enables support for NSS in QCA boards.
config PACKAGE_MAC80211_NSS_REDIRECT
bool "Enable autoloading with 'nss_redirect=1' (not needed on ath11k)"
depends on PACKAGE_MAC80211_NSS_SUPPORT
default n
help
This option enables autoloading mac80211 with 'nss_redirect=1'.
However, it is not required for wifi offloading.
endif
config PACKAGE_MAC80211_DEBUGFS
bool "Export mac80211 internals in DebugFS"
select KERNEL_DEBUG_FS
@ -281,6 +308,16 @@ ifeq ($(BUILD_VARIANT),smallbuffers)
C_DEFINES+= -DCONFIG_ATH10K_SMALLBUFFERS
endif
ifdef CONFIG_ATH11K_NSS_SUPPORT
IREMAP_CFLAGS+=-I$(STAGING_DIR)/usr/include/qca-nss-drv -I$(STAGING_DIR)/usr/include/qca-nss-clients
endif
ifeq ($(CONFIG_NSS_FIRMWARE_VERSION_11_4),y)
C_DEFINES+=-DCONFIG_NSS_FIRMWARE_VERSION_11_4
endif
config-$(CONFIG_PACKAGE_MAC80211_NSS_SUPPORT) += MAC80211_NSS_SUPPORT
MAKE_OPTS:= \
$(subst -C $(LINUX_DIR),-C "$(PKG_BUILD_DIR)",$(KERNEL_MAKEOPTS)) \
EXTRA_CFLAGS="-I$(PKG_BUILD_DIR)/include $(IREMAP_CFLAGS) $(C_DEFINES)" \
@ -354,6 +391,11 @@ define Build/Patch
$(call PatchDir,$(PKG_BUILD_DIR),$(PATCH_DIR)/mwl,mwl/)
$(call PatchDir,$(PKG_BUILD_DIR),$(PATCH_DIR)/brcm,brcm/)
$(call PatchDir,$(PKG_BUILD_DIR),$(PATCH_DIR)/rtl,rtl/)
ifdef CONFIG_ATH11K_NSS_SUPPORT
$(foreach driver,$(NSS_PATCH),
$(call PatchDir,$(PKG_BUILD_DIR),$(PATCH_DIR)/nss/$(driver),nss/$(driver)/)
)
endif
$(if $(QUILT),touch $(PKG_BUILD_DIR)/.quilt_used)
endef
@ -371,6 +413,11 @@ define Quilt/Refresh/Package
$(call Quilt/RefreshDir,$(PKG_BUILD_DIR),$(PATCH_DIR)/mwl,mwl/)
$(call Quilt/RefreshDir,$(PKG_BUILD_DIR),$(PATCH_DIR)/brcm,brcm/)
$(call Quilt/RefreshDir,$(PKG_BUILD_DIR),$(PATCH_DIR)/rtl,rtl/)
ifdef CONFIG_ATH11K_NSS_SUPPORT
$(foreach driver,$(NSS_PATCH),
$(call Quilt/RefreshDir,$(PKG_BUILD_DIR),$(PATCH_DIR)/nss/$(driver),nss/$(driver)/)
)
endif
endef
define Build/Compile
@ -392,6 +439,18 @@ define Build/InstallDev
rm -f $(1)/usr/include/mac80211-backport/linux/module.h
endef
ifdef CONFIG_ATH11K_NSS_SUPPORT
define KernelPackage/ath11k/install
$(INSTALL_DIR) $(1)/etc/init.d $(1)/etc/config $(1)/usr/bin $(1)/etc/hotplug.d/net
$(INSTALL_BIN) ./files/qca-nss-pbuf.init $(1)/etc/init.d/qca-nss-pbuf
$(INSTALL_DATA) ./files/pbuf.uci $(1)/etc/config/pbuf
$(INSTALL_BIN) ./files/nss_diag.sh $(1)/usr/bin/nss_diag
$(INSTALL_DATA) ./files/disable_mesh_chksum_ath11k.hotplug $(1)/etc/hotplug.d/net/99-disable_mesh_chksum_ath11k
echo "IPQ_BRANCH=$(IPQ_BRANCH)" > $(1)/etc/ipq_release
echo "IPQ_DATE=$(IPQ_DATE)" >> $(1)/etc/ipq_release
echo "IPQ_COMMIT=$(IPQ_COMMIT)" >> $(1)/etc/ipq_release
endef
endif
$(eval $(foreach drv,$(PKG_DRIVERS),$(call KernelPackage,$(drv))))
$(eval $(call KernelPackage,cfg80211))

View File

@ -13,7 +13,14 @@ PKG_CONFIG_DEPENDS += \
CONFIG_ATH10K_LEDS \
CONFIG_ATH10K_THERMAL \
CONFIG_ATH11K_THERMAL \
CONFIG_ATH_USER_REGD
CONFIG_ATH11K_DEBUGFS_STA \
CONFIG_ATH11K_DEBUGFS_HTT_STATS \
CONFIG_ATH_USER_REGD \
CONFIG_ATH11K_MEM_PROFILE_1G \
CONFIG_ATH11K_MEM_PROFILE_512M \
CONFIG_ATH11K_MEM_PROFILE_256M \
CONFIG_ATH11K_NSS_SUPPORT \
CONFIG_ATH11K_NSS_MESH_SUPPORT
ifdef CONFIG_PACKAGE_MAC80211_DEBUGFS
config-y += \
@ -59,6 +66,13 @@ config-$(CONFIG_ATH9K_UBNTHSR) += ATH9K_UBNTHSR
config-$(CONFIG_ATH10K_LEDS) += ATH10K_LEDS
config-$(CONFIG_ATH10K_THERMAL) += ATH10K_THERMAL
config-$(CONFIG_ATH11K_THERMAL) += ATH11K_THERMAL
config-$(CONFIG_ATH11K_MEM_PROFILE_1G) += ATH11K_MEM_PROFILE_1G
config-$(CONFIG_ATH11K_MEM_PROFILE_512M) += ATH11K_MEM_PROFILE_512M
config-$(CONFIG_ATH11K_MEM_PROFILE_256M) += ATH11K_MEM_PROFILE_256M
config-$(CONFIG_ATH11K_NSS_SUPPORT) += ATH11K_NSS_SUPPORT
config-$(CONFIG_ATH11K_NSS_MESH_SUPPORT) += ATH11K_NSS_MESH_SUPPORT
config-$(CONFIG_ATH11K_DEBUGFS_STA) += ATH11K_DEBUGFS_STA
config-$(CONFIG_ATH11K_DEBUGFS_HTT_STATS) += ATH11K_DEBUGFS_HTT_STATS
config-$(call config_package,ath9k-htc) += ATH9K_HTC
config-$(call config_package,ath10k,regular) += ATH10K ATH10K_PCI
@ -331,8 +345,16 @@ define KernelPackage/ath11k
URL:=https://wireless.wiki.kernel.org/en/users/drivers/ath11k
DEPENDS+= +kmod-ath +@DRIVER_11AC_SUPPORT +@DRIVER_11AX_SUPPORT \
+kmod-crypto-michael-mic +ATH11K_THERMAL:kmod-hwmon-core \
+ATH11K_THERMAL:kmod-thermal +kmod-qcom-qmi-helpers
+ATH11K_THERMAL:kmod-thermal +kmod-qcom-qmi-helpers \
+ATH11K_NSS_SUPPORT:kmod-qca-nss-drv \
+ATH11K_NSS_MESH_SUPPORT:kmod-qca-nss-drv-wifi-meshmgr \
+@(ATH11K_NSS_SUPPORT):NSS_DRV_WIFIOFFLOAD_ENABLE \
+@(ATH11K_NSS_SUPPORT):NSS_DRV_WIFI_EXT_VDEV_ENABLE
FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath11k/ath11k.ko
ifdef CONFIG_ATH11K_NSS_SUPPORT
AUTOLOAD:=$(call AutoProbe,ath11k)
MODPARAMS.ath11k:=nss_offload=1 frame_mode=2
endif
endef
define KernelPackage/ath11k/description
@ -340,6 +362,10 @@ This module adds support for Qualcomm Technologies 802.11ax family of
chipsets.
endef
define KernelPackage/ath11k/conffiles
/etc/config/pbuf
endef
define KernelPackage/ath11k/config
config ATH11K_THERMAL
@ -347,6 +373,63 @@ define KernelPackage/ath11k/config
depends on PACKAGE_kmod-ath11k
default y if TARGET_qualcommax
config ATH11K_DEBUGFS_STA
bool "Enable ath11k station statistics"
depends on PACKAGE_kmod-ath11k
depends on PACKAGE_MAC80211_DEBUGFS
default y
help
Say Y to enable access to the station statistics via debugfs.
config ATH11K_DEBUGFS_HTT_STATS
bool "Enable ath11k HTT statistics"
depends on PACKAGE_kmod-ath11k
depends on PACKAGE_MAC80211_DEBUGFS
default y
help
Say Y to enable access to the HTT statistics via debugfs.
config ATH11K_NSS_SUPPORT
bool "Enable NSS WiFi offload"
select ATH11K_MEM_PROFILE_512M
select PACKAGE_kmod-qca-nss-ecm
default y
help
Say Y to enable NSS WiFi offload support. Ensure you enable feeds for NSS drivers.
https://github.com/qosmio/nss-packages
config ATH11K_NSS_MESH_SUPPORT
bool "Enable NSS WiFi Mesh offload"
depends on ATH11K_NSS_SUPPORT
select PACKAGE_MAC80211_MESH
select NSS_FIRMWARE_VERSION_11_4
default n
choice
prompt "Memory Profile"
depends on PACKAGE_kmod-ath11k
default ATH11K_MEM_PROFILE_512M
help
This option allows you to select the memory profile.
It should correspond to the total RAM of your board.
config ATH11K_MEM_PROFILE_1G
bool "Use 1G memory profile"
help
This allows configuring ath11k for boards with 1GB+ memory.
config ATH11K_MEM_PROFILE_512M
bool "Use 512MB memory profile"
help
This allows configuring ath11k for boards with 512M memory.
The default is 1GB if not selected
config ATH11K_MEM_PROFILE_256M
bool "Use 256MB memory profile"
help
This allows configuring ath11k for boards with 256M memory.
The default is 1GB if not selected
endchoice
endef
define KernelPackage/ath11k-ahb

View File

@ -0,0 +1,24 @@
#!/bin/sh
# shellcheck disable=1090
PROG=${0##*/}
[ "$ACTION" = "add" ] && [ "$DEVTYPE" = "wlan" ] || exit 0
UEVENT="/sys/class/net/$INTERFACE/device/uevent"
[ -r "$UEVENT" ] || exit 0
DRIVER=$(awk -F= '/^DRIVER/{print $2}' "$UEVENT")
case "$DRIVER" in
*ath11k*)
mode=$(ubus call network.wireless status \
| jsonfilter -e "@[*].interfaces[@.ifname='$INTERFACE'].config.mode" 2> /dev/null)
[ "$mode" = "mesh" ] || exit 0
INC="/lib/netifd/offload/disable_offloads.sh"
. "$INC" 2> /dev/null || {
logger -t "$PROG" -p user.error "missing include script $INC. exiting..."
exit 1
}
disable_feature tx-checksumming "$INTERFACE"
;;
esac

View File

@ -0,0 +1,94 @@
#!/bin/sh
# shellcheck disable=3037,3060,2034,1091,2166
# check if stdout is a terminal, then set colors.
if [ -t 1 ]; then
red="\033[31m"
green="\033[32m"
yellow="\033[33m"
blue="\033[34m"
magenta="\033[35m"
cyan="\033[36m"
white="\033[37m"
reset="\033[m"
bold="\033[1m"
fi
# Retrieve Linux kernel
kernel=$(uname -r)
# Retrieve CPU freq mode
cpu_mode=$(cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor)
# Retrieve OpenWRT version
[ -r /etc/openwrt_version ] && openwrt_rev=$(cat /etc/openwrt_version)
# Retrieve device model
model=$(jsonfilter -e ''@.model.name'' < /etc/board.json | sed -e "s/,/_/g")
# NSS firmware version
nss_fw="/lib/firmware/qca*.bin"
# shellcheck disable=2086
[ "$(ls $nss_fw 2> /dev/null)" ] && nss_version=$(grep -h -m 1 -a -o 'Version:.[^[:cntrl:]]*' $nss_fw | head -1 | cut -d ' ' -f 2)
# ATH11K firmware version
ath11k_fw=$(grep -hm1 -a -o 'WLAN.[^[:cntrl:]]*SILICONZ-1' /lib/firmware/*/q6* | head -1)
# MAC80211 (backports) version
mac80211_version=$(awk '/version/{print $NF;exit}' /lib/modules/*/compat.ko)
# OpenWRT IPQ release details
[ -r /etc/ipq_release ] && . /etc/ipq_release
ipq_branch=${IPQ_BRANCH:-"N/A"}
ipq_commit=${IPQ_COMMIT:-"N/A"}
ipq_date=${IPQ_DATE:-"N/A"}
# Defaults for empty variables
kernel=${kernel:-"N/A"}
cpu_mode=${cpu_mode:-"N/A"}
openwrt_rev=${openwrt_rev:-"N/A"}
model=${model:-"N/A"}
nss_version=${nss_version:-"N/A"}
ath11k_fw=${ath11k_fw:-"N/A"}
mac80211_version=${mac80211_version:-"N/A"}
# Display the information
echo -e "${bold}${red} MODEL${reset}: ${cyan}${bold}${model}${reset}"
echo -e "${bold}${red} KERNEL${reset}: ${cyan}${bold}${kernel}${reset}"
echo -e "${bold}${red} CPU MODE${reset}: ${cyan}${bold}${cpu_mode}${reset}"
echo -e "${bold}${red} OPENWRT${reset}: ${green}${openwrt_rev}${reset}"
echo -e "${bold}${red}IPQ BRANCH${reset}: ${green}${ipq_branch}${reset}"
echo -e "${bold}${red}IPQ COMMIT${reset}: ${green}${ipq_commit}${reset}"
echo -e "${bold}${red} IPQ DATE${reset}: ${green}${ipq_date}${reset}"
echo -e "${bold}${red} NSS FW${reset}: ${yellow}${nss_version}${reset}"
echo -e "${bold}${red} MAC80211${reset}: ${yellow}${mac80211_version}${reset}"
echo -e "${bold}${red} ATH11K FW${reset}: ${yellow}${ath11k_fw}${reset}"
# Display GRO Fragmentation status using BusyBox
echo -ne "${bold}${red} INTERFACE${reset}: ${white}"
n=0
for iface in /sys/class/net/br-lan/device /sys/class/net/*/device; do
iface=${iface%/*}
iface=${iface##*/}
ethtool -k "$iface" | awk -v n=$n -v i="$iface" -v rst="${reset}" -v red="${red}" -v green="${green}" '
BEGIN { settings=""; if(n>0) spacing=" " }
/tx-checksumming|rx-gro-list/ {
color=green
if($2=="off") color=red
settings = settings $1 " " sprintf("%s%-3s%s", color,$2,rst) " ";
}
END { printf "%s%-11s%s\n", spacing, i, settings; }'
n=$((n + 1))
done
echo -e "${reset}"
echo -ne "${bold}${red} NSS PKGS${reset}: ${white}"
apk list -I | awk -v count=0 '
/kmod-qca|^nss/ {
if(count>0) tab=" "
print tab $1
count++
}'
echo -ne "${reset}"

View File

@ -0,0 +1,8 @@
config general opt
option auto_scale 'off'
# option memory_profile 'off'
option memory_profile 'auto'
# option memory_profile '1gb'
# option memory_profile '512mb'
# option memory_profile '256mb'
option scaling_governor 'schedutil'

View File

@ -0,0 +1,182 @@
#!/bin/sh /etc/rc.common
# shellcheck disable=3043,3010
# Copyright (c) 2021 The Linux Foundation. All rights reserved.
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
#
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#
START=95
NAME=qca-nss-pbuf
reload_wifi() {
if [ -r /sys/module/ath11k/parameters/nss_offload ]; then
nss_offload=$(cat /sys/module/ath11k/parameters/nss_offload 2> /dev/null)
[ "$nss_offload" -eq 1 ] && wifi up
fi
}
get_num_cpus() {
local num_cpus
num_cpus=$(awk -F': ' '/^processor/ {count++} END {print count}' /proc/cpuinfo)
echo "${num_cpus:-1}"
}
apply_sysctl() {
[ "$(sysctl -n -e dev.nss.general.redirect)" -eq 0 ] && /etc/init.d/qca-nss-ecm start
# Running this script multiple times is useless, as extra_pbuf_core0
# can't be changed if it is allocated, assume it's already been run.
if [ "$(sysctl -n -e dev.nss.n2hcfg.extra_pbuf_core0)" -eq 0 ]; then
logger -t $NAME "$board - setting dev.nss.n2hcfg.extra_pbuf_core0=$extra_pbuf_core0"
sysctl -w dev.nss.n2hcfg.extra_pbuf_core0="$extra_pbuf_core0" > /dev/null 2>&1
else
logger -t $NAME "Sysctl key 'extra_pbuf_core0' already set to '""$extra_pbuf_core0""'. Skipping applying wifi nss configs"
fi
sysctl -w dev.nss.n2hcfg.n2h_high_water_core0="$n2h_high_water_core0" > /dev/null 2>&1
logger -t $NAME "$board - setting dev.nss.n2hcfg.n2h_wifi_pool_buf=$n2h_wifi_pool_buf"
sysctl -w dev.nss.n2hcfg.n2h_wifi_pool_buf="$n2h_wifi_pool_buf" > /dev/null 2>&1
logger -t $NAME "$board - setting dev.nss.n2hcfg.n2h_high_water_core0=$n2h_high_water_core0"
sysctl -w dev.nss.n2hcfg.n2h_high_water_core0="$n2h_high_water_core0" > /dev/null 2>&1
}
apply_nss_config() {
local auto_scale n2h_queue_limit_core0 n2h_queue_limit_core1 num_cpus
local hash_bitmap
if [ ! -r /sys/module/ath11k/parameters/nss_offload ]; then
logger -t $NAME "Module parameter '/sys/module/ath11k/parameters/nss_offload' does NOT exist. Skipping applying wifi nss configs"
exit 1
fi
enable_nss_offload=$(cat /sys/module/ath11k/parameters/nss_offload)
if [ "$enable_nss_offload" -ne "1" ]; then
logger -t $NAME -s user.warn "Module parameter 'nss_offload=0'. Skipping applying wifi nss configs"
exit 1
fi
[ ! -d "/proc/sys/dev/nss/rps" ] && {
logger -s -t $NAME -p user.error "NSS driver not loaded or disabled! Exiting... "
exit 1
}
config_load pbuf
config_get_bool auto_scale opt auto_scale 0
config_get n2h_queue_limit_core0 opt n2h_queue_limit_core0 256
config_get n2h_queue_limit_core1 opt n2h_queue_limit_core1 256
sysctl -w dev.nss.clock.auto_scale="$auto_scale" > /dev/null 2>&1
sysctl -w dev.nss.n2hcfg.n2h_queue_limit_core0="$n2h_queue_limit_core0" > /dev/null 2>&1
sysctl -w dev.nss.n2hcfg.n2h_queue_limit_core1="$n2h_queue_limit_core1" > /dev/null 2>&1
local memory_profile memtotal board
board=$(board_name)
if memory_profile=$(uci_get pbuf.opt.memory_profile); then
case "$memory_profile" in
1024 | 1g* | 512 | 512m* | 256 | 256m*)
logger -t $NAME "Using custom memory profile - $board"
;;
off* | false* | disable* | 0)
logger -s -t $NAME -p user.warn "NSS pbuf option 'memory_profile=off'. Not running. Enable if you have issues connecting more than 65 clients"
exit 0
;;
auto)
memtotal=$(awk '/MemTotal/{print $2}' /proc/meminfo)
[ "$memtotal" -gt 512000 ] && memory_profile=1024
[ "$memtotal" -le 512000 ] && memory_profile=512
[ "$memtotal" -le 256000 ] && memory_profile=256
logger -t $NAME "Setting n2hcfg values for board: $board"
;;
*)
logger -s -t $NAME -p user.error "Unknown profile $memory_profile. Choose auto, 1gb, 512mb, or 256mb"
exit 1
;;
esac
else
exit 0
fi
case "$memory_profile" in
# 1GB+ profile
1024 | 1g*)
extra_pbuf_core0=10000000 n2h_high_water_core0=72512 n2h_wifi_pool_buf=36864 apply_sysctl
;;
# 512MB profile
512 | 512m*)
extra_pbuf_core0=3100000 n2h_high_water_core0=30624 n2h_wifi_pool_buf=8192 apply_sysctl
;;
# 256MB profile
256 | 256m*)
extra_pbuf_core0=3100000 n2h_high_water_core0=30258 n2h_wifi_pool_buf=4096 apply_sysctl
;;
esac
}
set_stats_disable() {
local stats_disable
config_load pbuf
config_get stats_disable opt stats_disable 1
find /sys/kernel/debug/ath11k -name stats_disable | while read -r stats_file; do
stats_msg_prefix="Disabling"
[ "$stats_disable" -eq 0 ] && stats_msg_prefix="Enabling"
logger -t $NAME -p user.notice "$stats_msg_prefix ath11k stats"
echo "$stats_disable" > "$stats_file"
done
}
set_scaling_governor() {
local scaling_governor num_cpus
config_load pbuf
config_get scaling_governor opt scaling_governor
scaling_available_governors=/sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
if [ -r "$scaling_available_governors" ]; then
scaling_available_governors=$(cat $scaling_available_governors)
else
return 0
fi
if [ -n "$scaling_available_governors" ] && [ -n "$scaling_governor" ]; then
if [[ "$scaling_available_governors" =~ $scaling_governor ]]; then
logger -t $NAME -p user.notice "Setting CPU scaling governor to '$scaling_governor'"
num_cpus=$(get_num_cpus)
for num in $(seq 0 $((num_cpus - 1))); do
echo "$scaling_governor" > "/sys/devices/system/cpu/cpu${num}/cpufreq/scaling_governor"
done
else
logger -t $NAME -p user.error "'$scaling_governor' not available in CPU governors [ $scaling_available_governors ]"
fi
fi
}
start() {
set_scaling_governor
set_stats_disable
apply_nss_config
num_cpus=$(get_num_cpus)
hash_bitmap="$(((1 << num_cpus) - 1))"
sysctl -w dev.nss.rps.hash_bitmap=$hash_bitmap > /dev/null 2>&1
reload_wifi
}

View File

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath10k/mac.c
+++ b/drivers/net/wireless/ath/ath10k/mac.c
@@ -9919,6 +9919,21 @@ static int ath10k_mac_init_rd(struct ath
@@ -9920,6 +9920,21 @@ static int ath10k_mac_init_rd(struct ath
return 0;
}
@ -22,7 +22,7 @@
int ath10k_mac_register(struct ath10k *ar)
{
static const u32 cipher_suites[] = {
@@ -10281,6 +10296,12 @@ int ath10k_mac_register(struct ath10k *a
@@ -10282,6 +10297,12 @@ int ath10k_mac_register(struct ath10k *a
ar->hw->weight_multiplier = ATH10K_AIRTIME_WEIGHT_MULTIPLIER;

View File

@ -40,7 +40,7 @@ Signed-off-by: Mathias Kresin <dev@kresin.me>
if (ret)
--- a/drivers/net/wireless/ath/ath10k/mac.c
+++ b/drivers/net/wireless/ath/ath10k/mac.c
@@ -10297,7 +10297,7 @@ int ath10k_mac_register(struct ath10k *a
@@ -10298,7 +10298,7 @@ int ath10k_mac_register(struct ath10k *a
ar->hw->weight_multiplier = ATH10K_AIRTIME_WEIGHT_MULTIPLIER;
#ifdef CPTCFG_MAC80211_LEDS

View File

@ -18,7 +18,7 @@ Signed-off-by: David Bauer <mail@david-bauer.net>
--- a/drivers/net/wireless/ath/ath10k/mac.c
+++ b/drivers/net/wireless/ath/ath10k/mac.c
@@ -10090,7 +10090,6 @@ int ath10k_mac_register(struct ath10k *a
@@ -10091,7 +10091,6 @@ int ath10k_mac_register(struct ath10k *a
ieee80211_hw_set(ar->hw, CHANCTX_STA_CSA);
ieee80211_hw_set(ar->hw, QUEUE_CONTROL);
ieee80211_hw_set(ar->hw, SUPPORTS_TX_FRAG);

Some files were not shown because too many files have changed in this diff Show More