Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\aio.c Create Date:2022-07-28 20:21:18
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:io_submit_one

Proto:static int io_submit_one(struct kioctx *ctx, struct iocb __user *user_iocb, bool compat)

Type:int

Parameter:

TypeParameterName
struct kioctx *ctx
struct iocb __user *user_iocb
boolcompat
1855  If Value for the false possibility is greater at compile time(copy_from_user( & iocb, user_iocb, size of iocb )) Then Return -EFAULT
1859  If Value for the false possibility is greater at compile time(TODO: use this for a (struct sigevent *) ) Then
1860  pr_debug("EINVAL: reserve field set\n")
1861  Return -EINVAL
1865  If Value for the false possibility is greater at compile time((aio_buf != (unsignedlong)aio_buf) || (aio_nbytes != (size_t)aio_nbytes) || ((ssize_t)aio_nbytes < 0)) Then
1870  pr_debug("EINVAL: overflow check\n")
1871  Return -EINVAL
1874  req = aio_get_req* Allocate a slot for an aio request.* Returns NULL if no requests are free.* The refcount is initialized to 2 - one for the async op completion,* one for the synchronous code that does this.
1875  If Value for the false possibility is greater at compile time(!req) Then Return -EAGAIN
1878  err = __io_submit_one(ctx, & iocb, user_iocb, req, compat)
1881  iocb_put(req)
1888  If Value for the false possibility is greater at compile time(err) Then
1889  iocb_destroy(req)
1890  put_reqs_available(ctx, 1)
1892  Return err
Caller
NameDescribe
SYSCALL_DEFINE3sys_io_submit:* Queue the nr iocbs pointed to by iocbpp for processing
COMPAT_SYSCALL_DEFINE3