Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:disk_check_events

Proto:static void disk_check_events(struct disk_events *ev, unsigned int *clearing_ptr)

Type:void

Parameter:

TypeParameterName
struct disk_events *ev
unsigned int *clearing_ptr
1851  disk = he associated disk
1852  char * envp[( size of disk_uevents / sizeof((disk_uevents)[0]) + ((int)(sizeof(struct{int : ( - !!(__builtin_types_compatible_p(typeof((disk_uevents)), typeof( & (disk_uevents)[0]))));})))) + 1] = {}
1853  clearing = clearing_ptr
1856  nr_events = 0
1859  events = check_events(disk, clearing)
1862  spin_lock_irq( & lock)
1864  events &= ~vents already sent out
1865  vents already sent out |= events
1866  clearing_ptr &= ~clearing
1868  intv = disk_events_poll_jiffies(disk)
1869  If Not vent blocking depth && intv Then queue_delayed_work - queue work on a workqueue after delay*@wq: workqueue to use*@dwork: delayable work to queue*@delay: number of jiffies to wait before queueing* Equivalent to queue_delayed_work_on() but tries to use the local CPU.
1873  spin_unlock_irq( & lock)
1881  When i < ARRAY_SIZE - get the number of elements in array @arr*@arr: array to be sized(disk_uevents) cycle If events & supported events & 1 << i && flags related to event processing & DISK_EVENT_FLAG_UEVENT Then
1884  envp[nr_events++] = disk_uevents[i]
1886  If nr_events Then kobject_uevent_env - send an uevent with environmental data*@kobj: struct kobject that the action is happening to*@action: action that is happening*@envp_ext: pointer to environmental data* Returns 0 if kobject_uevent_env() is completed with success or the
Caller
NameDescribe
disk_clear_eventsdisk_clear_events - synchronously check, clear and return pending events*@disk: disk to fetch and clear events from*@mask: mask of events to be fetched and cleared* Disk events are synchronously checked and pending events in @mask
disk_events_workfnSeparate this part out so that a different pointer for clearing_ptr can be* passed in for disk_clear_events.