Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:__get_reqs_available

Proto:static bool __get_reqs_available(struct kioctx *ctx)

Type:bool

Parameter:

TypeParameterName
struct kioctx *ctx
922  bool ret = false
925  local_irq_save(flags)
926  kcpu = this_cpu_ptr(cpu)
927  If Not reqs_available Then
928  avail = atomic_read( & * 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)
930  Do
934  old = avail
937  When avail != old cycle
939  reqs_available += * For percpu reqs_available, number of slots we move to/from global * counter at a time:
942  ret = true
943  reqs_available--
944  out :
945  local_irq_restore(flags)
946  Return ret
Caller
NameDescribe
get_reqs_available