Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:block\elevator.c Create Date:2022-07-28 16:57:58
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:elv_register

Proto:int elv_register(struct elevator_type *e)

Type:int

Parameter:

TypeParameterName
struct elevator_type *e
533  If see iocontext.h Then
534  If WARN_ON( see iocontext.h < sizeof(structio_cq)) || WARN_ON( ditto < __alignof__(structio_cq)) Then Return -EINVAL
538  snprintf - Format a string and place it in a buffer*@buf: The buffer to place the result into*@size: The size of the buffer, including the trailing null space*@fmt: The format string to use*@
540  managed by elevator core = kmem_cache_create - Create a cache.*@name: A string which is used in /proc/slabinfo to identify this cache.*@size: The size of objects to be created in this cache.*@align: The required alignment for the objects.*@flags: SLAB flags
542  If Not managed by elevator core Then Return -ENOMEM
547  spin_lock( & elv_list_lock)
548  If levator_find - Find an elevator*@name: Name of the elevator to find*@required_features: Features that the elevator must provide* Return the first registered scheduler with name @name and supporting the* features @required_features and NULL otherwise. Then
549  spin_unlock( & elv_list_lock)
550  kmem_cache_destroy( managed by elevator core )
551  Return -EBUSY
553  list_add_tail - add a new entry*@new: new entry to be added*@head: list head to add it before* Insert a new entry before the specified head.* This is useful for implementing queues.
554  spin_unlock( & elv_list_lock)
556  printk - print a kernel message*@fmt: format string* This is printk(). It can be called from any context. We want it to work.* We try to grab the console_lock. If we succeed, it's easy - we log the* output and call the console drivers
558  Return 0
Caller
NameDescribe
deadline_init
kyber_init
bfq_init