函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:put_reqs_available

函数原型:static void put_reqs_available(struct kioctx *ctx, unsigned nr)

返回类型:void

参数:

类型参数名称
struct kioctx *ctx
unsignednr
907  local_irq_save(flags)
908  kcpu等于this_cpu_ptr(cpu)
909  reqs_available加等于nr
911 reqs_available大于等于* For percpu reqs_available, number of slots we move to/from global * counter at a time:乘2循环
912  reqs_available减等于* For percpu reqs_available, number of slots we move to/from global * counter at a time:
913  atomic_add(* For percpu reqs_available, number of slots we move to/from global * counter at a time:, & * This counts the number of available slots in the ringbuffer, * so we avoid overflowing it: it's decremented (if positive) * when allocating a kiocb and incremented when the resulting * io_event is pulled off the ringbuffer. * We batch accesses to it with)
916  local_irq_restore(flags)
调用者
名称描述
refill_reqs_availablell_reqs_available* Updates the reqs_available reference counts used for tracking the* number of free slots in the completion ring. This can be called* from aio_complete() (to optimistically update reqs_available) or
io_submit_one