Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:dev_alloc() - allocate a cdev structure* Allocates and returns a cdev structure, or NULL on failure.

Proto:struct cdev *cdev_alloc(void)

Type:struct cdev

Parameter:Nothing

632  p = 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).
633  If p Then
634  Initialization list head
635  kobject_init() - Initialize a kobject structure
637  Return p
Caller
NameDescribe
__register_chrdev__register_chrdev() - create and register a cdev occupying a range of minors*@major: major device number or 0 for dynamic allocation*@baseminor: first of the requested range of minor numbers*@count: the number of minor numbers required*@name: name of this