rt_ssize_t can give negative error code, which follows the unix style correctly
Co-authored-by: Wayne Lin <wclin@nuvoton.com>