Hung-Te Lin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/42029 )
Change subject: drivers/vpd: Add a function that reads BIOS version from a VPD variable ......................................................................
Patch Set 6:
That is correct: in our build process the firmware version is set after the original build. The reason is that we create release candidates with non-stable version numbers a coreboot-dirty-$HASH is fine for an RC). Then we test extensively the firmware image, and if everything is good we assign a "stable" version number (with a different numbering scheme from the non-stable ones).
If the stable is usually shorter than coreboot-dirty-$HASH, have you considered about applying a tag tool, that can replace a string in blob?
Another reason to use VPD was that these variables are easily accessible via Linux's /sys/firmware/vpd , so no vpd tool is necessary.
But if you are already dealing with smbios, dmidecode should give you same information by "sudo dmidecode -s bios-version".