There is no need to use kernel build for S-mode all the time. As cpu scratch is supported for non kernel mode build, it is possible to use flat build for S-mode. Add flat build support for risc-v S mode. Signed-off-by: Inochi Amaoto <inochiama@outlook.com>