How to check the firmware version that my QSPI has?

Hello, I am new to VF2 and I have some questions. I have the Vision Five 2 v1.3B that I recently purchased. I have tried booting through NVME but it does not boot from SD correctly. This are my questions:

  1. How can I check the firmware version that my QSPI Flash has installed?
  2. If my firmware is not updated to version v3.7.5, can I use the flashcp method? There is a note that says Method 2 only supports versions equal to or later than VF2_v2.5.0. Is my recently purchased VF2 v1.3B board old?
  3. Has anyone tried NVME boot with firmware v3.7.5 when the micro switches are to boot via QSPI Flash and there is one operating system on the SD and another on the NVME, which one boots first?
    Thank you so much

I wrote a quick and dirty script to check what version was written to the QSPI (but it does assumed that the version written to the QSPI was one that was U-boot and publicly published at https://github.com/starfive-tech/VisionFive2/releases ). So if you compiled your own or the version installed was not publicly published then my script will output nothing. But obviously my script (and data file) needs an OS running on the machine to be able to access the 1-bit QSPI NOR FLASH.

A second method is possible if you have a 3.3 volt USB to serial UART connected to your board during boot you will see messages like the following:
U-Boot SPL 2021.10 (Mar 22 2023 - 19:45:47 +0800)
DDR version: dc2e84f0.”
and
U-Boot 2021.10 (Mar 22 2023 - 19:45:47 +0800), Build: jenkins-VF2_515_Branch_SDK_Release-38”
The above would correspond to VF2_v2.10.4 which was used with VisionFive 2 Debian Image 202302.

Or
U-Boot SPL 2021.10 (Aug 23 2023 - 11:14:54 +0800)
LPDDR4: 8G version: g8ad50857.”
and
U-Boot 2021.10 (Aug 23 2023 - 11:14:54 +0800), Build: jenkins-VisionFive2-SDK-Components-172”
The above would correspond to VF2_v3.6.1 which was used with VisionFive 2 Debian Image 202308

The dates and times above would correspond to the date and time that the SPL+U-Boot (u-boot-spl.bin.normal.out) and U-Boot+SBI (visionfive2_fw_payload.img) were compiled and the approximate firmware version can be guessed by looking at the release dates at https://github.com/starfive-tech/VisionFive2/releases or trying to find where the date would approximately fit in the table below which is derived from the publicly published U-Boot firmwares:

user@dong:~/SPI_firmware$ find `find . -name "*_VF2_*" -print | sort -n` -type f -print | xargs md5sum
f30ad74a0d92807d8e0027d69fba32ac  ./2022-12-12_VF2_v2.4.4/u-boot-spl.bin.normal.out
316a2504dd5bc9c807a25d7d3616e25b  ./2022-12-12_VF2_v2.4.4/visionfive2_fw_payload.img
1a8e399f270982acc6de88bb21bc9070  ./2022-12-25_VF2_v2.5.0/u-boot-spl.bin.normal.out
fb4dabdefecd21ebcd8b0c3c84174aea  ./2022-12-25_VF2_v2.5.0/visionfive2_fw_payload.img
dae53441f842ec1619e5d7fc17edb3a8  ./2023-01-09_VF2_v2.6.0/u-boot-spl.bin.normal.out
0bae62d9f0e4176d4253c8b23173e567  ./2023-01-09_VF2_v2.6.0/visionfive2_fw_payload.img
c44036b3a07ec93a165b76ec3df0704e  ./2023-01-19_VF2_v2.8.0/u-boot-spl.bin.normal.out
21ae1a326e9ab5c52a7502da059d7bc5  ./2023-01-19_VF2_v2.8.0/visionfive2_fw_payload.img
491934f6454fd6b7b48199f8900a1a39  ./2023-02-28_VF2_v2.10.4/u-boot-spl.bin.normal.out
bf51e6a61373a2a9058a9169bb74c6ef  ./2023-02-28_VF2_v2.10.4/visionfive2_fw_payload.img
1118cf69644d7565a4fc8c70de72dddb  ./2023-03-25_VF2_v2.11.5/u-boot-spl.bin.normal.out
f294bb0fd8972718078d11a6b7321f18  ./2023-03-25_VF2_v2.11.5/visionfive2_fw_payload.img
4cb6beece0179092b006b4c72a08e49a  ./2023-05-31_VF2_v3.0.4/u-boot-spl.bin.normal.out
99df7275c60eb7057aeb41b78075de78  ./2023-05-31_VF2_v3.0.4/visionfive2_fw_payload.img
a87f0d3a02b194d494b553088ff16f01  ./2023-07-02_VF2_v3.1.5/u-boot-spl.bin.normal.out
e0238fcf7f354dd4089d3d5f5bd894c9  ./2023-07-02_VF2_v3.1.5/visionfive2_fw_payload.img
0c18b40c209957e62baa939efb18541f  ./2023-08-08_VF2_v3.4.5/u-boot-spl.bin.normal.out
959fbdb32fee949c7ddaa3151559bb73  ./2023-08-08_VF2_v3.4.5/visionfive2_fw_payload.img
e8570dd7b2d4e988698ca0de422f0861  ./2023-08-31_VF2_v3.6.1/u-boot-spl.bin.normal.out
ed7bd86fa97ebcbc39efedd99df3db96  ./2023-08-31_VF2_v3.6.1/visionfive2_fw_payload.img
8ca05f3a39944407b636a69456bfb296  ./2023-09-26_VF2_v3.7.5/u-boot-spl.bin.normal.out
452013678845508e3ea54b35e9ad840a  ./2023-09-26_VF2_v3.7.5/visionfive2_fw_payload.img
user@dong:~/SPI_firmware$

All of the above does assume that you are using U-Boot, and not the edk2 EFI firmware (https://github.com/starfive-tech/edk2/releases) , to boot your board.

2 Likes

Thanks, I had a serial-USB converter and I was able to see the firmware version that my board has by entering U-boot

2 Likes

Sorry for necroposting :smiley:

If serial connection not available, to find out the firmware version on a booted system, we can use something like:

user@starfive:~$ sudo cat /dev/mtd[012] | strings | grep -E "U-Boot SPL|buildroot"
U-Boot SPL 2021.10 (May 09 2024 - 22:42:02 +0800)
riscv64-buildroot-linux-gnu-gcc.br_real (Buildroot JH7110_VF2_515_v5.12.0) 12.2.0
user@starfive:~$
3 Likes