|
|
Subscribe / Log in / New account

The cdev interface

The cdev interface

Posted Jun 11, 2010 10:51 UTC (Fri) by nosf (guest, #67468)
Parent article: The cdev interface

>* In order the device to actually apear in the file system, you have to >call device_create (class, parent_dev, devno, device_name).
>* In order to call device_create you need to have a device class object: >either use one of the existing classes, or create your own with create_class (THIS_MODULE, class_name)

I think this is for sysfs only.


to post comments

The cdev interface

Posted Aug 30, 2015 8:49 UTC (Sun) by netilovefm (guest, #101569) [Link]

now I have a question. I want to use this char_dev.

I see chrdev_open() function, in that function,

why in this function calls request_module() if not matching cdev and i_node->i_cdev

cdev is already added in system(usually module_init()function) then why call module again?

help me and answer plz T.T


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds