With the implemented functions you can recover bootloader in ch32v20x/30x chips.
I have not tested ch32F family, but if the flash controller is the same, it "should" work.
sfdp parser from: https://raw.githubusercontent.com/petris/sfdp-parser/master/sfdp-parser.c
More here: https://michaldemin.wordpress.com/2023/05/06/wch-ch32v20x-30x-risc-v-flash-memory/https://michaldemin.wordpress.com/2023/09/27/wch-ch32v20x-30x-risc-v-flash-memory/