Commit 5aac039
tun: honor IOCB_NOWAIT flag
tun only checks the file O_NONBLOCK flag, but it should also be checking
the iocb IOCB_NOWAIT flag. Any fops using ->read/write_iter() should check
both, otherwise it breaks users that correctly expect O_NONBLOCK semantics
if IOCB_NOWAIT is set.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Link: https://lore.kernel.org/r/e9451860-96cc-c7c7-47b8-fe42cadd5f4c@kernel.dk
Signed-off-by: Jakub Kicinski <kuba@kernel.org>1 parent c5dab09 commit 5aac039
1 file changed
Lines changed: 11 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1961 | 1961 | | |
1962 | 1962 | | |
1963 | 1963 | | |
| 1964 | + | |
1964 | 1965 | | |
1965 | 1966 | | |
1966 | 1967 | | |
1967 | 1968 | | |
1968 | | - | |
1969 | | - | |
| 1969 | + | |
| 1970 | + | |
| 1971 | + | |
| 1972 | + | |
1970 | 1973 | | |
1971 | 1974 | | |
1972 | 1975 | | |
| |||
2185 | 2188 | | |
2186 | 2189 | | |
2187 | 2190 | | |
| 2191 | + | |
2188 | 2192 | | |
2189 | 2193 | | |
2190 | 2194 | | |
2191 | | - | |
| 2195 | + | |
| 2196 | + | |
| 2197 | + | |
| 2198 | + | |
| 2199 | + | |
2192 | 2200 | | |
2193 | 2201 | | |
2194 | 2202 | | |
| |||
0 commit comments