Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:disk_add_events

Proto:static void disk_add_events(struct gendisk *disk)

Type:void

Parameter:

TypeParameterName
struct gendisk *disk
2048  If sysfs_create_files( & kobj, disk_events_attrs) < 0 Then pr_warn("%s: failed to create sysfs files for events\n", name of major driver )
2052  If Not ev Then Return
2055  mutex_lock( & list of all disk_events )
2056  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.
2057  mutex_unlock - release the mutex*@lock: the mutex to be released* Unlock a mutex that has been locked by this task previously.* This function must not be used in interrupt context. Unlocking* of a not locked mutex is not allowed.
2063  __disk_unblock_events(disk, true)
Caller
NameDescribe
__device_add_disk__device_add_disk - add disk information to kernel list*@parent: parent device for the disk*@disk: per-device partitioning information*@groups: Additional per-device sysfs groups*@register_queue: register the queue if set to true* This function registers