[PATCH 5.13 119/127] riscv: Fix a number of free'd resources in init_resources()