函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:__io_free_req

函数原型:static void __io_free_req(struct io_kiocb *req)

返回类型:void

参数:

类型参数名称
struct io_kiocb *req
944  ctx等于ctx
946  如果io释放内存
948  如果file且非flags按位与ctx owns file 的值则fput(file)
950  如果flags按位与 inflight list
953  spin_lock_irqsave( & inflight_lock, flags)
954  删除链表项
955  如果waitqueue_active -- locklessly test for waiters on the queue*@wq_head: the waitqueue to test for waiters* returns true if the wait list is not empty* NOTE: this function is lockless and requires care, incorrect usage _will_wake_up( & inflight_wait)
957  spin_unlock_irqrestore( & inflight_lock, flags)
959  percpu计数引用减
960  如果此条件成立可能性大(为编译器优化)(!io_is_fallback_req(req))则kmem_cache_free(req_cachep, req)
962  否则lear_bit_unlock - Clear a bit in memory, for unlock*@nr: the bit to set*@addr: the address to start counting from* This operation is atomic and provides release barrier semantics.
调用者
名称描述
io_free_req
io_put_req_find_nextDrop reference to request, return next in chain (if there is one) if this* was the last reference to this request.
__io_double_put_req
io_submit_sqes