Yeah, I've just realized that seeing a huge archive inside. So nice to have it. Thank you so much once again!
Disclaimer: I'm neither an OpenWrt developer nor project member, nor have any say in approving or opposing your PR, the below is just my personal opinion in the hope to improve the situation.
From what I see at PR#18118, there are multiple issues that make it impossible to merge the PR as is:
- Each commit must have a valid Signed-off-by: tag including a real name/ mail address, this is a formal copyright attestation (in the sense that you are allowed to submit your changes (i.e. you hold the copyright) and do formally sign off your contribution)
While this is a formality, it is a hard requirement and must be part of every single commit, if Microsoft (via github) knows your name is immaterial here, it must be stated as Signed-off for each commit to provide the proper copyright attribution, some projects might accept pseudonymous contributions, OpenWrt does not.
'Everything' can be fixed by others, if they care to do so, except for the copyright situation (so the Signed-off-by needs to be in order, or no one can even look at the changes). - based on the scope of these changes, there should only be a single (atomic) commit/ patch adding support for this device, and no spurious merge commit.
So the PR should be rebased and the changes squashed into a single commit. - The (single) commit adding support for this device needs to list the hardware specs and installation instructions
- I have not reviewed the actual changes
Thank you, I shall rework the commit.
Hey guys, I've been messing around with buildroot imagebuilder these days, which I am very new to for now. Still, I've been able to extract original DTS from Fudy QWRT firmware, and it has Mediatek HNAT features and some other things. It's a v1 old format. I've been able to add it to hanwick immortalwrt 21.02 fork made specially for mediatek devices, build, flashed it and it's working. The only thing is MAC addresses are random, and I could not connect via eth0 LAN to the router. It shows the link but doesn't give an IP address via DHCP. WAN eth1 works fine.
Here is the original QWRT DTS https://pastebin.com/LZWSzyRs maybe you can help me at least with making OpenWRT 21.02 LAN work.
Otherwise, @hecatae would you please check if there is any useful, important info in this original DTS that we can use in OpenWRT 24?
P.S. Looks like it has a little bit better wifi compared to ImmortalWRT 24 and the vanilla OpenWRT 24 build I've tested from @hecatae
@dunsky 21.02 is end of life, and what you are asking is can you use something that is not actually Openwrt found over here: https://git01.mediatek.com/plugins/gitiles/openwrt/feeds/mtk-openwrt-feeds/
I cannot help with building a end of life Openwrt SDK fork with proprietary drivers.
Hey, no issues. I understand. I just received my USB TTL, and it's finally working! Do you still want me to check the output from the factory firmware and your build?
Hey guys, do you know why if I use same DTS and set platform.sh and all the things mentioned in the PR above to last stable 23.05.5 OpenWRT my device don't boot? Maybe there is something essential missing? As I can see via UART boot stuck at
loop: module loaded
Somehow system can't see mmcblvk0p6
partition and mount /rom
and /overlay
out of it.
Looking at the DTS, I see there's a partition definition at the end. It might not be compatible with the vanilla layout.
You're right, thank you so much! When I removing
this part
card@0 {
compatible = "mmc-card";
reg = <0>;
block {
compatible = "block-device";
partitions {
block-partition-factory {
partname = "factory";
nvmem-layout {
compatible = "fixed-layout";
#address-cells = <1>;
#size-cells = <1>;
eeprom_factory_0: eeprom@0 {
reg = <0x0 0x1000>;
};
macaddr_factory_4: macaddr@4 {
compatible = "mac-base";
reg = <0x4 0x6>;
#nvmem-cell-cells = <1>;
};
};
};
};
};
};
The device boots normally to OpenWRT 23.05.5!
I have a question. When I am removing partitions part from DTS mmc definition, then device boots to 23.05.5, but have no eth0 LAN. Somehow if I add this to ð and to &mdio_bus
#address-cells = <1>;
#size-cells = <0>;
Device start booting even with partitions definition and eth0
starts working. But there is no wifi.
mt798x-wmac 18000000.wifi: WM Firmware Version: ____000000, Build Time: 20221208201806
[ 12.371980] mt798x-wmac 18000000.wifi: WA Firmware Version: DEV_000000, Build Time: 20221208202048
[ 12.463640] mt798x-wmac 18000000.wifi: eeprom load fail, use default bin
[ 12.470421] mt798x-wmac 18000000.wifi: Direct firmware load for mediatek/mt7981_eeprom_mt7976_dbdc.bin failed with error -2
[ 12.481554] mt798x-wmac 18000000.wifi: Falling back to sysfs fallback for: mediatek/mt7981_eeprom_mt7976_dbdc.bin
[ 12.515386] mt798x-wmac: probe of 18000000.wifi failed with error -12
If I manually download eeprom
dd if=/dev/mmcblk0p2 of=/lib/firmware/mediatek/mt7981_eeprom_mt7976_dbdc.bin
After reboot, the wifi works. phy0-ap0
even gets it's real factory MAC.
mt798x-wmac 18000000.wifi: HW/SW Version: 0x8a108a10, Build Time: 20221208201745a
[ 7.872517]
[ 8.032645] mt798x-wmac 18000000.wifi: WM Firmware Version: ____000000, Build Time: 20221208201806
[ 8.127166] mt798x-wmac 18000000.wifi: WA Firmware Version: DEV_000000, Build Time: 20221208202048
[ 8.219014] mt798x-wmac 18000000.wifi: eeprom load fail, use default bin
[ 8.323415] mt798x-wmac 18000000.wifi: registering led 'mt76-phy0'
[ 8.365985] mt798x-wmac 18000000.wifi: registering led 'mt76-phy1'
Am I missing something essential? Maybe there is a special file like 02_network
or platform.sh
which I can edit to make wifi work immediately after flashing OpenWRT 23.05.5?
P.S. Here is my last edited DTS which is working in OpenWRT 23.05.5
UPD: Looks like I've found it and now I see why OpenWRT 24.10 is more developed - this stuff is working out of the box there. In OpenWRT 23 there are lot's of scripts. For my case I think I need target/linux/mediatek/filogic/base-files/lib/preinit/81_fix_eeprom
to extract eeprom from /dev/mmcblk0p2
to /lib/firmware/mediatek/mt7981_eeprom_mt7976_dbdc.bin
. I'll check now...
Hey guys, I've been able to make the official OpenWRT 23.05.5 release work on this "Fudy Shmoody" device, finally! I don't know there is any sense in making it work. I was doing it just for fun. But I have a question: Do you think I shall create a PR for 23.05.5, or is it impossible for now, and is the official branch frozen with old devices only?
I had to add fix_eeprom
script to
. /lib/functions/caldata.sh
preinit_fix_eeprom() {
case $(board_name) in
huasifei,wh3000-emmc)
mmc_part=$(find_mmc_part factory)
FIRMWARE="mediatek/mt7981_eeprom_mt7976_dbdc.bin"
[ ! -e /lib/firmware/"$FIRMWARE" ] && \
export FIRMWARE="$FIRMWARE" && \
caldata_extract_mmc "factory" 0x0 0x1000
;;
esac
}
boot_hook_add preinit_main preinit_fix_eeprom
While booting, the system was unable to read eeprom somehow, and I had to force download it to the file via this script.
Now everything is set; factory MACs are there, and LAN, WAN, and wifi are working. So far, so good.
new devices are always added to master, not an existing (or old) release.
once you get the PR merged, you can create a backport, and add the device to the next minor release of the current stable.
Next minor release of the current stable means something like 24.10.1
?
yes.
you can look up the TR3000, it was back ported to 23.05, in the middle of the minor release cycle.
Thank you for your answers! I was able to build 23.05.5 with the correct vermagic, finally! Everything works fine but...
Do you have any clue why on my build I have a strange bug? If I update base-files
via opkg
, it makes the whole system crash sending filesystem to RO. Then, after reboot, everything works. But if I try to do a reset, all my current settings come back. Something is not resetting properly.
opkg install base-files
Upgrading base-files on root from 1-r24106-10cc5fcd00 to 1562-r24106-10cc5fcd00...
Downloading https://downloads.openwrt.org/releases/23.05.5/targets/mediatek/filogic/packages/base-files_1562-r24106-10cc5fcd00_aarch64_cortex-a53.ipk
//usr/lib/opkg/info/base-files.prerm: line 198: /etc/init.d/bootcount: Permission denied
umount: mountd(pid2193) busy - remounted read-only
umount: devpts busy - remounted read-only
umount: tmpfs busy - remounted read-only
umount: can't remount tmpfs read-only
umount: proc busy - remounted read-only
Collected errors:
* copy_file: unable to open `/etc/group-opkg.backup': Read-only file system.
* file_copy: Failed to copy file /etc/group to /etc/group-opkg.backup.
* backup_make_backup: Failed to copy /etc/group to /etc/group-opkg.backup
* opkg_install_cmd: Cannot install package base-files.
* pkg_write_filelist: Failed to open //usr/lib/opkg/info/base-files.list: Read-only file system.
Then even after "reset" or flashing sysupgrade without saving settings I got RO.
firstboot -y
MTD partition 'rootfs_data' not found
My device configuration is mmcblck0p6
partition is squashfs with /rom
and /overlay
mounted as loop0
PR is closed ?
(post deleted by author)
Well I read it already before I wrote that message (since I was in that conversation) but still don't get it. As I understand it was rejected several times due to not passing test formalities but what is the reason for closing it?
Because that's what @hecatae decided.
There's a new PR https://github.com/openwrt/openwrt/pull/18220
If /overlay is running full, it'll become RO, but I don't know if this is the case here.