How to create proc entry under /proc/driver?
I want to create a file under a /proc/driver directory. I would like to use a macro like proc_root_driver (or something else provided) rather than use "driver/MODULE_NAME" explicitly. I use create_proc_entry : struct proc_dir_entry *simpleproc_fops_entry; simpleproc_fops_entry = create_proc_entry(MODULE_NAME, 0400, NULL /* proc_root_dir */); After googling, I found suggestion to use proc_root_driver , but when I use it, I get the error proc_root_driver undeclared in this function And also, proc_root_driver is not available in linux/proc_fs.h. I have tried to declare structure like this: struct