函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\aio.c Create Date:2022-07-29 10:53:33
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:io_submit_one

函数原型:static int io_submit_one(struct kioctx *ctx, struct iocb __user *user_iocb, bool compat)

返回类型:int

参数:

类型参数名称
struct kioctx *ctx
struct iocb __user *user_iocb
boolcompat
1855  如果此条件成立可能性小(为编译器优化)(copy_from_user( & iocb, user_iocb, iocb的长度))则返回:负EFAULT
1859  如果此条件成立可能性小(为编译器优化)(TODO: use this for a (struct sigevent *) )则
1860  pr_debug("EINVAL: reserve field set\n")
1861  返回:负EINVAL
1865  如果此条件成立可能性小(为编译器优化)((读写操作对应的内存 != (unsignedlong)读写操作对应的内存) || (需要读写的字节长度 != (size_t)需要读写的字节长度) || ((ssize_t)需要读写的字节长度 < 0))则
1870  pr_debug("EINVAL: overflow check\n")
1871  返回:负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  如果此条件成立可能性小(为编译器优化)(!req)则返回:负EAGAIN
1878  err等于__io_submit_one(ctx, & iocb, user_iocb, req, compat)
1881  iocb_put(req)
1888  如果此条件成立可能性小(为编译器优化)(err)则
1889  iocb_destroy(req)
1890  put_reqs_available(ctx, 1)
1892  返回:err
调用者
名称描述
SYSCALL_DEFINE3sys_io_submit:* Queue the nr iocbs pointed to by iocbpp for processing
COMPAT_SYSCALL_DEFINE3