Support for RTL838x based managed switches

I added complete image generation including mtdsplit and working sysupgrade to my HPE 1920 branch. This includes support for HPE 1920-8G/-16G/-24G/-48G, although only the 16G variant is tested so far, as I don't have any of the other devices. But at least the 24G model is also very likely to work, as it seems to use the same board.

Instructions for running an initramfs image from memory, as well as permanent installation are in the commit message.

For anyone trying this, it would be nice if you could check if the MAC address assignment matches stock firmware, as I'm not entirely sure if it is correct. You can get the interface MAC addresses and lots of additional information using these commands on stock firmware:

_cmdline-mode on  # enable full command-line access
Jinhua1920unauthorized  # password
display diagnostic-information

There are still a few things that need cleanup (but for testing this shouldn't matter):

  • The firmware-utils part obviously doesn't belong in this repository, but for now it is easier this way.

  • 7z compression relies on the 7z command line tool being available on the build host. While the source of the lzma host package includes code for 7z archives, the 7z command line tool seems to be Windows-only in that old version. I don't really like the 7z command line tool anyway, as it doesn't provide a way to explicitly specify an unencoded header (as required by the bootloader). It looks like that just happens to be the default in some cases. But I'm also not sure what the alternative would be.

  • A proper fix to avoid LED initialization in arch/mips/rtl838x/setup.c is needed. I assume this is actually necessary for the system LED to work on other devices, so I don't know what a proper solution should look like?

1 Like