Add a separate firmware package to avoid installing the MT7615 firmware
on all MT7622 target devices by default. Now we only add MT7615 firmware
packages for devices that use MT7615E. This commit also removes the
explicit dependency on kmod-mt7615e to refine the package dependency.
Signed-off-by: Shiji Yang <yangshiji66@qq.com>
The mt7915e driver supports MT7915, MT7916 and MT7986 chips. And Only
MT7915 series chips need the MT7915 firmware. To save storage, extract
them from the common code package and create a new package to provide
the firmware.
Signed-off-by: Shiji Yang <yangshiji66@qq.com>
The kmod-mt7615-common package does not contain any code that
related to mt7915e Wi-Fi6 driver, so remove it.
Tested on ramips/mt7621: SIM SIMAX1800T
Signed-off-by: Shiji Yang <yangshiji66@qq.com>
limit dictionary size patch was introduced to solve the well known
"LZMA ERROR 1 - must RESET board to recover" error.
09b6755946 "ramips: limit dictionary size for lzma compression"
It seems that it has failed recently and we can use lzma loader to fix
this error by adding "$(Device/uimage-lzma-loader)". So just remove it
to use the default parameter -d24 for a higher compression ratio.
Signed-off-by: Shiji Yang <yangshiji66@qq.com>
Make the patches apply cleanly again.
Fixes: 8dfe69cdfc ("kernel: update nvmem subsystem to the latest upstream")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
1. Check for -EPROBE_DEFER
If it occurs we have to return immediately. Trying other properties
could result in another error and ignoring -EPROBE_DEFER which has a
special meaning.
2. Check for read result
Assuming property->read() success can result in NULL pointer
dereference. It happens e.g. for "mac-address" with NVMEM cell
containing invalid MAC.
3. Simplify code
Don't move cell reading & nvmem_cell_put() into a loop. Simplify loop
code.
Fixes: ecd81de7a5 ("ath79: add nvmem cell mac-address-ascii support")
Cc: Yousong Zhou <yszhou4tech@gmail.com>
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
This is no longer needed now that the kernel is built with a load
address that matches the one hard-coded in the bootloader.
Signed-off-by: Jan Hoffmann <jan@3e8.eu>
In order to maximize the available space on UniFi AC boards using a
dual-image partition layout, combine the two OS partitions into a single
partition.
This allows users to access more usable space for additional packages.
Don't limit the usable image size to the size of a single OS partition.
The initial installation has to be done with an older version of OpenWrt
in case the generated image exceeds the space of a single kernel
partition in the future.
Signed-off-by: David Bauer <mail@david-bauer.net>
In order to maximize the available space on USW-Flex boards using a
dual-image partition layout, combine the two OS partitions into a single
partition.
This allows users to access more usable space for additional packages.
Don't limit the usable image size to the size of a single OS partition.
The initial installation has to be done with an older version of OpenWrt
in case the generated image exceeds the space of a single kernel
partition in the future.
Signed-off-by: David Bauer <mail@david-bauer.net>
In order to maximize the available space on OCEDO boards using a
dual-image partition layout, combine the two OS partitions into a single
partition.
This allows users to access more usable space for additional packages.
Don't limit the usable image size to the size of a single OS partition.
The initial installation has to be done with an older version of OpenWrt
in case the generated image exceeds the space of a single OS
partition in the future.
Signed-off-by: David Bauer <mail@david-bauer.net>
The GL-MV1000 ships with a 16MB spi-nor flash, containing a copy of the stock GL.iNet firmware.
Add the corresponding flash areas, so our view matches the one of the in-flash stock firmware.
Signed-off-by: Enrico Mioso <mrkiko.rs@gmail.com>
Specifications
SoC: MT7621
CPU: 880 MHz
Flash: 32 MiB
RAM: 256 MiB
WLAN: MT7915 WiFi 6 (2.4/5 GHz)
Ethernet: 2x Gbit ports
MAC
LAN b4:4b:d6:2e:c7:b0 (label)
WAN b4:4b:d6:2e:c7:b1
WiFi 2.4 00:0c:43:26:46:08
WiFi 5 00:0c:43:26:59:97
Installation
There are two known options:
1) The Luci-based UI.
2) Press and hold the reset button during power up.
The router will request 'recovery.bin' from a TFTP server at
192.168.1.88.
Both options require a signed firmware binary.
The openwrt image supplied by cudy is signed and can be used to
install unsigned images.
Signed-off-by: Leon M. Busch-George <leon@georgemail.eu>
The EN25QH256A variant of the EN25QH256 doesn't initialize correctly from SFDP
alone and only accesses memory below 8m (addr_width is 4 but read_opcode takes
only 3 bytes).
Set SNOR_F_4B_OPCODES if the flash chip variant was detected using hwcaps.
The fix submitted upstream uses the PARSE_SFDP initializer that is not
available in the kernel used with Openwrt.
Signed-off-by: Leon M. Busch-George <leon@georgemail.eu>
22.03.1+ and snapshot builds no longer fit the 6M flash space
available for these models.
This disables failing buildbot image builds for these devices.
Images can still be built manually with ImageBuilder.
Signed-off-by: Joe Mullally <jwmullally@gmail.com>
This commits adds the makefile targets `depends` this wrapper is a call
to `opkg depends`. This command shows which runtime dependencies exist
if this package is installed into the image.
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
Pull the calibration data from the nvmem subsystem. This allows us to
move userspace caldata extraction into the device-tree definition.
Merge art into partition node.
Signed-off-by: Stefan Kalscheuer <stefan@stklcode.de>
Keenetic KN-1613 is a 2.4/5 Ghz band 11ac (Wi-Fi 5) router, based on MT7628AN.
Specification:
- System-On-Chip: MT7628AN
- CPU/Speed: 580 MHz
- Flash-Chip: Winbond w25q256
- Flash size: 32768 KiB
- RAM: 128 MiB
- 4x 10/100 Mbps Ethernet
- 2x external, non-detachable antennas
- UART (J1) header on PCB (115200 8n1)
- Wireless No1 (2T2R): SoC Built-in 2.4 GHz 802.11bgn
- Wireless No2 (2T2R): MT7613BE 5 GHz 802.11ac
- 4x LED, 2x button, 1x mode switch
Notes:
- The device supports dual boot mode
- The firmware partitions were concatinated into one
- The FN button led indicator has been reassigned as the 2.4GHz
wifi indicator.
Flash instruction:
The only way to flash OpenWrt image is to use tftp recovery mode in U-Boot:
1. Configure PC with static IP 192.168.1.2/24 and tftp server.
2. Rename "openwrt-ramips-mt76x8-keenetic_kn-1613-squashfs-factory.bin"
to "KN-1613_recovery.bin" and place it in tftp server directory.
3. Connect PC with one of LAN ports, press the reset button, power up
the router and keep button pressed until power led start blinking.
4. Router will download file from server, write it to flash and reboot.
Signed-off-by: Maxim Anisimov <maxim.anisimov.ua@gmail.com>
A huge rewrite in libpcap was introduced by dc14a7babca1 ("rpcap: have
the server tell the client its byte order.") [0]. The patch
"201-space_optimization.patch" does not apply at all anymore. So remove
it.
Refresh:
- 100-no-openssl.patch
- 102-skip-manpages.patch
Update the "300-Add-support-for-B.A.T.M.A.N.-Advanced.patch" with latest
PR [1].
old ipkg size:
90964 bin/packages/mips_24kc/base/libpcap1_1.10.1-5_mips_24kc.ipk
new ipkg size:
93340 bin/packages/mips_24kc/base/libpcap1_1.10.2-1_mips_24kc.ipk
[0] - dc14a7babc
[1] - https://github.com/the-tcpdump-group/libpcap/pull/980
Signed-off-by: Nick Hainke <vincent@systemli.org>
Fix Silicon Labs bindings in the spidev driver
Some bindings for Silicon Labs chips already exists upstream.
These bindings can be found in trivial-devices.yaml.
The existing bindings are using "silabs" instead of "siliconlabs" to
identify the manufacturer.
This commit add two submitted patches for silabs chips and rename the
manufacturer in the different DTS for more coherence.
Signed-off-by: Vincent Tremblay <vincent@vtremblay.dev>
FCC ID: U2M-CAP4100AG
Fortinet FAP-221-B is an indoor access point with
1 Gb ethernet port, dual-band wireless,
internal antenna plates, and 802.3at PoE+
Hardware and board design from Senao
**Specification:**
- AR9344 SOC 2G 2x2, 5G 2x2, 25 MHz CLK
- AR9382 WLAN 2G 2x2 PCIe, 40 MHz CLK
- AR8035-A PHY RGMII, PoE+ IN, 25 MHz CLK
- 16 MB FLASH MX25L12845EMI-10G
- 2x 32 MB RAM W9725G6JB-25
- UART at J11 populated, 9600 baud
- 6 LEDs, 1 button power, ethernet, wlan, reset
Note: ethernet LEDs are not enabled
because a new netifd hotplug is required
in order to operate like OEM.
Board has 1 amber and 1 green
for each of the 3 case viewports.
**MAC addresses:**
1 MAC Address in flash at end of uboot
ASCII encoded, no delimiters
Labeled as "MAC Address" on case
OEM firmware sets offsets 1 and 8 for wlan
eth0 *:1e uboot 0x3ff80
phy0 *:1f uboot 0x3ff80 +1
phy1 *:26 uboot 0x3ff80 +8
**Serial Access:**
Pinout: (arrow) VCC GND RX TX
Pins are populated with a header and traces not blocked.
Bootloader is set to 9600 baud, 8 data, 1 stop.
**Console Access:**
Bootloader:
Interrupt boot with Ctrl+C
Press "k" and enter password "1"
OR
Hold reset button for 5 sec during power on
Interrupt the TFTP transfer with Ctrl+C
to print commands available, enter "help"
OEM:
default username is "admin", password blank
telnet is available at default address 192.168.1.2
serial is available with baud 9600
to print commands available, enter "help"
or tab-tab (busybox list of commands)
**Installation:**
Use factory.bin with OEM upgrade procedures
OR
Use initramfs.bin with uboot TFTP commands.
Then perform a sysupgrade with sysupgrade.bin
**TFTP Recovery:**
Using serial console, load initramfs.bin using TFTP
to boot openwrt without touching the flash.
TFTP is not reliable due to bugged bootloader,
set MTU to 600 and try many times.
If your TFTP server supports setting block size,
higher block size is better.
Splitting the file into 1 MB parts may be necessary
example:
$ tftpboot 0x80100000 image1.bin
$ tftpboot 0x80200000 image2.bin
$ tftpboot 0x80300000 image3.bin
$ tftpboot 0x80400000 image4.bin
$ tftpboot 0x80500000 image5.bin
$ tftpboot 0x80600000 image6.bin
$ bootm 0x80100000
**Return to OEM:**
The best way to return to OEM firmware
is to have a copy of the MTD partitions
before flashing Openwrt.
Backup copies should be made of partitions
"fwconcat0", "loader", and "fwconcat1"
which together is the same flash range
as OEM's "rootfs" and "uimage"
by loading an initramfs.bin
and using LuCI to download the mtdblocks.
It is also possible to extract from the
OEM firmware upgrade image by splitting it up
in parts of lengths that correspond
to the partitions in openwrt
and write them to flash,
after gzip decompression.
After writing to the firmware partitions,
erase the "reserved" partition and reboot.
**OEM firmware image format:**
Images from Fortinet for this device
ending with the suffix .out
are actually a .gz file
The gzip metadata stores the original filename
before compression, which is a special string
used to verify the image during OEM upgrade.
After gzip decompression, the resulting file
is an exact copy of the MTD partitions
"rootfs" and "uimage" combined in the same order and size
that they appear in /proc/mtd and as they are on flash.
OEM upgrade is performed by a customized busybox
with the command "upgrade".
Another binary, "restore"
is a wrapper for busybox's "tftp" and "upgrade".
Signed-off-by: Michael Pratt <mcpratt@pm.me>
Some vendors use basic gzip metadata (original filename and timestamp)
to verify valid images, along with the size of it's contents.
Also, add a new device profile variable FACTORY_IMG_NAME
which would be ideal to use with this new recipe.
Signed-off-by: Michael Pratt <mcpratt@pm.me>
It's necessary to be able to specify the length
for MAC addresses that are stored in flash, for example,
in a case where it is stored without any delimiter.
Let both offset and length have default values.
Add a sanity check related to partition size.
Also, clean up syntax and unnecessary lines.
Signed-off-by: Michael Pratt <mcpratt@pm.me>
Some vendors of Senao boards have a similar flash layout
situation that causes the need to split the firmware partition
and use the lzma-loader, but do not store
checksums of the partitions or otherwise
do not even have a uboot environment partition.
This adds simple shell logic to skip that part.
Also, simplify some lines and variable usage.
Signed-off-by: Michael Pratt <mcpratt@pm.me>
Some vendors of Senao boards have put a bootloader
that cannot handle both large gzip or large lzma files.
There is no disadvantage by doing this for all of them.
Signed-off-by: Michael Pratt <mcpratt@pm.me>
In target/linux/realtek/files-5.15/drivers/net/dsa/rtl83xx/rtl838x.c,
make rtl838x_pie_rule_write() return non-zero value case of error.
Signed-off-by: Pascal Ernster <git@hardfalcon.net>
Make sure functions calling rtl838x_smi_wait_op() return its return
value in target/linux/realtek/files-5.15/drivers/net/dsa/rtl83xx/rtl838x.c.
This brings the code style in line with the rtl839x implementation.
Suggested-by: Sander Vanheule <sander@svanheule.net>
Signed-off-by: Pascal Ernster <git@hardfalcon.net>
A behavioural change was introduced with commit 758c88b969 ("realtek:
Whitespace and codestyle cleanup") causing rtl838x_read_phy() and
rtl838x_write_phy() to unconditionally return -ETIMEDOUT. As a result,
probing the device during boot fails:
Error setting up netdev, freeing it again.
rtl838x-eth: probe of 1b00a300.ethernet failed with error -5
Fix the bootloop caused by this regression with kernel 5.15 on rtl838x
devices, by properly returning 0 on success.
Tested on a Netgear GS108T v3, a Netgear GS310TP v1, a Zyxel GS1900-8HP
v1 and an HPE 1920-8G.
Fixes: 758c88b969 ("realtek: Whitespace and codestyle cleanup")
Tested-by: Stijn Segers <foss@volatilesystems.org>
Tested-by: Jan Hoffmann <jan@3e8.eu>
Signed-off-by: Pascal Ernster <git@hardfalcon.net>
Upstream generic MIPS uses 0x80100000 and 0x80100400 for the LOADADDR
and ENTRY addresses. As we do not want to diverge from upstream and
patch upstream when not needed, adjust our addresses as well to be
future proof.
Signed-off-by: Olliver Schinagl <oliver@schinagl.nl>
Tested-by: Jan Hoffmann <jan@3e8.eu> # HPE 1920-8G, HPE 1920-48G
Add 32M build target
Rest of the details as per commit 46ab81e405 ("ramips add support for
UniElec U7621-06")
Signed-off-by: Ignas Poklad <ignas2526@gmail.com>
Pull the calibration data from the nvmem subsystem. This allows us to
move userspace caldata extraction into the device-tree definition.
Merge art into partition node.
Signed-off-by: Nick Hainke <vincent@systemli.org>
The WIFI LED already worked for me with the latest openwrt 22.03 version.
Wifi LED did not with an older 22.x version (in gluon - there phy0radio did nothing but phy0tpt did show activity
the WAN interface has the name "wan" and not "pppoe-wan" on this device
fixes#7757 (and FS#2987)
Signed-off-by: Florian Maurer <f.maurer@outlook.de>
ChangeLog:
Version 2.16.01
_This is a documentation update release only._
(*) Fix the creation of the table of contents in the HTML version of
the documentation.
Version 2.16
(*) Support for the `rdf' format has been discontinued and all the
RDOFF utilities has been removed.
(*) The `--reproducible' option now leaves the filename field in the
COFF object format blank. This was always rather useless since
it is only 18 characters long; as such debug formats have to
carry their own filename information anyway.
(*) Fix handling of MASM-syntax reserved memory (e.g. `dw ?') when
used in structure definitions.
(*) The preprocessor now supports functions, which can be less
verbose and more convenient than the equivalent code implemented
using directives. See section 4.4.
(*) Fix the handling of `%00' in the preprocessor.
(*) Fix incorrect handling of path names affecting error messages,
dependency generation, and debug format output.
(*) Support for the RDOFF output format and the RDOFF tools have
been removed. The RDOFF tools had already been broken since at
least NASM 2.14. For flat code the ELF output format
recommended; for segmented code the `obj' (OMF) output format.
(*) New facility: preprocessor functions. Preprocessor functions,
which are expanded similarly to single-line macros, can greatly
simplify code that in the past would have required a lengthy
list of directives and intermediate macros. See section 4.4.
(*) Single-line macros can now declare parameters (using a `&&'
prefix) that creates a quoted string, but does _not_ requote an
already quoted string. See section 4.2.1.
(*) Instruction table updated per public information available as of
November 2022.
(*) All warnings in the preprocessor have now been assigned warning
classes. See appendix A.
(*) Fix the invalid use of `RELA'-type relocations instead of `REL'-
type relocations when generating DWARF debug information for the
`elf32' output format.
(*) Fix the handling `at' in `istruc' when the structure contains
local labels. See section 5.9.2.
(*) When assembling with `--reproducible', don't encode the filename
in the COFF header for the `coff', `win32' or `win64' output
formats. The COFF header only has space for an 18-character
filename, which makes this field rather useless in the first
place. Debug output data, if enabled, is not affected.
(*) Fix incorrect size calculation when using MASM syntax for non-
byte reservations (e.g. `dw ?'.)
(*) Allow forcing an instruction in 64-bit mode to have a (possibly
redundant) REX prefix, using the syntax `{rex}' as a prefix.
(*) Add a `{vex}' prefix to enforce VEX (AVX) encoding of an
instruction, either using the 2- or 3-byte VEX prefixes.
(*) The `CPU' directive has been augmented to allow control of
generation of VEX (AVX) versus EVEX (AVX-512) instruction
formats, see section 7.11.
(*) Some recent instructions that previously have been only
available using EVEX encodings are now also encodable using VEX
(AVX) encodings. For backwards compatibility these encodings are
not enabled by default, but can be generated either via an
explicit `{vex}' prefix or by specifying either `CPU LATEVEX' or
`CPU NOEVEX'; see section 7.11.
(*) Document the already existing `%unimacro' directive. See section
4.5.12.
(*) Fix a code range generation bug in the DWARF debug format
(incorrect information in the `DW_AT_high_pc' field) for the ELF
output formats. This bug happened to cancel out with a bug in
older versions of the GNU binutils linker, but breaks with other
linkers and updated or other linkers that expect the spec to be
followed.
(*) Fix segment symbols with addends, e.g. `jmp _TEXT+10h:0' in
output formats that support segment relocations, e.g. the `obj'
format.
(*) Fix various crashes and hangs on invalid input.
Signed-off-by: Linhui Liu <liulinhui36@gmail.com>