Commit 9f0f659
iomap: error out on file IO when there is no inline_data buffer
[ Upstream commit 6a96fb653b6481ec73e9627ade216b299e4de9ea ]
Return IO errors if an ->iomap_begin implementation returns an
IOMAP_INLINE buffer but forgets to set the inline_data pointer.
Filesystems should never do this, but we could help fs developers (me)
fix their bugs by handling this more gracefully than crashing the
kernel.
Signed-off-by: Darrick J. Wong <[email protected]>
Link: https://lore.kernel.org/175803480324.966383.7414345025943296442.stgit@frogsfrogsfrogs
Reviewed-by: Christoph Hellwig <[email protected]>
Signed-off-by: Christian Brauner <[email protected]>
Signed-off-by: Sasha Levin <[email protected]>1 parent 8167718 commit 9f0f659
2 files changed
Lines changed: 13 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
304 | 304 | | |
305 | 305 | | |
306 | 306 | | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
307 | 310 | | |
308 | 311 | | |
309 | 312 | | |
| |||
894 | 897 | | |
895 | 898 | | |
896 | 899 | | |
897 | | - | |
| 900 | + | |
898 | 901 | | |
899 | 902 | | |
900 | 903 | | |
| |||
903 | 906 | | |
904 | 907 | | |
905 | 908 | | |
| 909 | + | |
| 910 | + | |
| 911 | + | |
906 | 912 | | |
907 | 913 | | |
908 | 914 | | |
909 | 915 | | |
910 | 916 | | |
911 | 917 | | |
| 918 | + | |
912 | 919 | | |
913 | 920 | | |
914 | 921 | | |
| |||
921 | 928 | | |
922 | 929 | | |
923 | 930 | | |
924 | | - | |
925 | | - | |
926 | | - | |
927 | | - | |
| 931 | + | |
| 932 | + | |
928 | 933 | | |
929 | 934 | | |
930 | 935 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
519 | 519 | | |
520 | 520 | | |
521 | 521 | | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
522 | 525 | | |
523 | 526 | | |
524 | 527 | | |
| |||
0 commit comments