1__GENERIC_FILE_AIO_W(9)   Memory Management in Linux   __GENERIC_FILE_AIO_W(9)
2
3
4

NAME

6       __generic_file_aio_write - write data to a file
7

SYNOPSIS

9       ssize_t __generic_file_aio_write(struct kiocb * iocb,
10                                        const struct iovec * iov,
11                                        unsigned long nr_segs, loff_t * ppos);
12

ARGUMENTS

14       iocb
15           IO state structure (file, offset, etc.)
16
17       iov
18           vector with data to write
19
20       nr_segs
21           number of segments in the vector
22
23       ppos
24           position where to write
25

DESCRIPTION

27       This function does all the work needed for actually writing data to a
28       file. It does all basic checks, removes SUID from the file, updates
29       modification times and calls proper subroutines depending on whether we
30       do direct IO or a standard buffered write.
31
32       It expects i_mutex to be grabbed unless we work on a block device or
33       similar object which does not need locking at all.
34
35       This function does *not* take care of syncing data in case of O_SYNC
36       write. A caller has to handle it. This is mainly due to the fact that
37       we want to avoid syncing under i_mutex.
38
40Kernel Hackers Manual 2.6.         June 2019           __GENERIC_FILE_AIO_W(9)
Impressum