Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:ioctx_add_table

Proto:static int ioctx_add_table(struct kioctx *ctx, struct mm_struct *mm)

Type:int

Parameter:

TypeParameterName
struct kioctx *ctx
struct mm_struct *mm
639  spin_lock( & ioctx_lock)
640  table = Dependency order vs. p above. (ioctx_table)
642  When 1 cycle
643  If table Then When i < nr cycle
646  id = i
657  Return 0
660  new_nr = If table Then nr Else 1 * 4
661  spin_unlock( & ioctx_lock)
663  table = kzalloc - allocate memory. The memory is set to zero.*@size: how many bytes of memory are required.*@flags: the type of memory to allocate (see kmalloc).
665  If Not table Then Return -ENOMEM
668  nr = new_nr
670  spin_lock( & ioctx_lock)
671  old = Dependency order vs. p above. (ioctx_table)
673  If Not old Then
675  Else if nr > nr Then
676  memcpy(table, table, nr * size of * )
681  Else
682  kfree(table)
683  table = old
Caller
NameDescribe
ioctx_allocx_alloc* Allocates and initializes an ioctx. Returns an ERR_PTR if it failed.