mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
mirror O_APPEND and O_DIRECT into iocb->ki_flags
... avoiding write_iter/fcntl races. Signed-off-by: Al Viro <[email protected]>
This commit is contained in:
parent
3309dd04cb
commit
2ba48ce513
11 changed files with 38 additions and 23 deletions
2
fs/aio.c
2
fs/aio.c
|
|
@ -1502,7 +1502,7 @@ static int io_submit_one(struct kioctx *ctx, struct iocb __user *user_iocb,
|
|||
}
|
||||
req->common.ki_pos = iocb->aio_offset;
|
||||
req->common.ki_complete = aio_complete;
|
||||
req->common.ki_flags = 0;
|
||||
req->common.ki_flags = iocb_flags(req->common.ki_filp);
|
||||
|
||||
if (iocb->aio_flags & IOCB_FLAG_RESFD) {
|
||||
/*
|
||||
|
|
|
|||
Loading…
Reference in a new issue