The problem I noticed is that the partition table on the QSPI NOR FLASH from Linux is seen as:
|device name|Device offset|Env. size |Flash sector size|Label|
|-----------|-------------|----------|-----------------|-----|
|/dev/mtd1 |0x0000000 |0x00020000|0x00020000 |SPL |
|/dev/mtd2 |0x0100000 |0x00300000|0x00300000 |UBOOT|
|/dev/mtd3 |0x0F00000 |0x01000000|0x01000000 |DATA |
But the way that it is actually used by U-Boot according to the “JH7110Boot User Guide (page 8)” is:
|device name|Device offset|Env. size |Flash sector size|Contents |
|-----------|-------------|----------|-----------------|---------------------------------|
| |0x0000000 |0x00080000|0x00080000 |SPL |
| |0x00F0000 |0x00010000|0x00010000 |U-Boot environment variables |
| |0x0100000 |0x00400000|0x00400000 |fw_payload.img (OpenSBI + U-Boot)|
| |0x0600000 |0x01000000|0x01000000 |Reseved |
So from Linux there is currently no raw partition to access the U-Boot environment variables using “libubootenv”. You could create a new partition that points to the U-Boot environment variables and create a /etc/fw_env.config file that point to that, but probably far safer to wait on the next image to arrive which will probably align the partitions with the documentation, although I just spotted a typo, but it is nothing important.