Skip to main content.

5.3.4. The open and release methods


open and release:

int open(struct inode *i, struct file *filp)
int release(struct inode *i, struct file *filp)

find device numbers given an inode:

unsigned int imajor(struct inode* i);
unsigned int iminor(struct inode* i);

find containing structure:

container_of(container_field_ptr, container_type, name_of_container_field);
5.3.3. Registering a character driver 1. Denx Training Topics 5.3.5. The read and write system calls
Prev Home Next