F2FS: Upstream updates
f2fs: use inner macro and function to clean up codes
f2fs: introduce f2fs_write_failed to handle error case when write