There's an error in https://github.com/openwrt/openwrt/pull/21511 .
It's missing a saveenv after the 1st setenv command, it makes the initramfs boot with working network, but after you've flashed the sysupgrade image, there's no network anymore, since the new bootcmd wasn't saved.
Searching the forum, people have ran into this.
Can a merged PR be reopened, to fix this ?
1 Like
It is usual to open a "bugfix" or "patch" PR and get that merged.
Probably best to open a Github issue and ping toshipp to bring his attention to it.
slh
March 12, 2026, 10:46am
3
Once merged, the old PR no longer applies and you need to open a new one with the bugfix.
2 Likes
that's fine, but will the old "disappear" ?
having two PRs, one correct and the other one incorrect is almost as bad as having only the incorrect one.
sorry if questions seem stupid, I'm not very familiar with GH
The old PR was merged, so it is now in the code base. It shows up on Github as "closed" and is no longer a Pull Request.
Opening a new PR, once it is merged, will update the code base with the fix.
You could actually make a comment on the old PR, starting with @toshipp to make sure he gets a notification. Explain the issue and see if he answers.
2 Likes
I see.
I don't think I've realized which parts actually make it into the code base.
basically you can submit a patch where no code is changed, only comment(s).
You can see files or changed files that go into the code base, for example for this merged PR, here:
main ← toshipp:xikestor-sks8300-8t
XikeStor SKS8300-8T is a 8 ports Multi-Gig switch, based on the RTL9303.
Specif… ications:
- SoC : Realtek RTL9303
- RAM : DDR3 512 MiB
- Flash : SPI-NOR 32 MiB (Macronix)
- CPU : 800MHz
- Ethernet : 8× 1G/2.5G/5G/10G Base-T RJ45 ports (RTL8261N)
- Keys (GPIO) : 1x
- UART : "Console" port on the front panel
- type : RS-232C
- connector : RJ-45
- settings : 115200 8N1
- Power : 12 VDC, 4A
- Temperature sensor : LM75 or compatible
- Fan controller : SensyLink CTF2302
Flash instruction using initramfs image:
1. Prepare TFTP server & connect to serial port.
2. Connect your computer to one of the RJ45 ports on SKS8300-8T
3. Power on SKS8300-8T and interrupt autoboot with Shift + A.
4. Use Shift + Q to drop from vendor CLI to U-Boot CLI.
5. Set the boot command to enable network on boot.
> setenv bootcmd 'mw.l 0x8401da94 0; rtk network on; boota'
6. Set switch IP and TFTP server IP (optional, adjust to your setup).
> setenv ipaddr <ip>
> setenv serverip <ip>
7. Download initramfs image from TFTP server.
> tftpboot 0x83000000 <image name>
8. Boot with the downloaded image.
> bootm 0x83000000
9. With rambooted OpenWrt, backup the stock firmware if needed.
10. Copy sysupgrade image to the device.
11. Perform sysupgrade with the sysupgrade image.
12. After reboot, you should have functional OpenWrt.
In OpenWrt, it is necessary to execute "rtk network on" to enable full
networking functionality. However, the internal U-Boot initialization
(which shares logic with "rtk network init" initializing MAC only and
configures the fan controller) sets a flag at memory address 0x8401da94.
Once this flag is set, any subsequent calls to "rtk network on" are
blocked. To bypass this, resetting 0x8401da94 to 0 by step 5, ensuring
that the network can be properly initialized later. This specific
address was confirmed in U-Boot 2011.12.(3.6.11.55242) (Jan 06 2025 -
14:39:46) by decompiling the function that references the "rtk_mac_init"
string.
Reverting to stock firmware:
1. Connect to serial port.
2. Power on SKS8300-8T and interrupt autoboot with Shift + A.
3. Use Shift + Q to drop from vendor CLI to U-Boot CLI.
4. Set the boot command to the firmware default.
> setenv bootcmd boota
5. Enable network.
> rtk network on
6. Boot OpenWrt.
> boota
7. Download latest firmware from XikeStor and upload to your device.
8. Write firmware with 'sysupgrade -F'.
9. After reboot, stock firmware should boot automatically.
Co-authored-by: Samy Younsi <kame@duck.com>
Signed-off-by: FUKAYA Toshikuni <toshiq2@neenana.org>
Link: https://github.com/openwrt/openwrt/pull/21511
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
yeah, I probably would have figured it out eventually, if I had looked into the commits a little harder ,)
anyway, I've added a comment to the old PR.
thnx @bluewavenet and @slh .
Indeed. When you first start looking at git stuff it all seems like black magic, or at least it did to me.
PRs are not always the clearest to follow either. Then don't get me started on the fact that some people with the access rights to do so, sometimes get sloppy and push directly into master/main instead of opening a PR where it can be reviewed.
Even if they merged their own PR's, at least there would be an easy to follow path/ audit-trail of how things got changed.. But I digress
1 Like