Ex5.1 Q4

If we use 

 alloc_chrdev_region 

WHY do we need the 

 major_num 
and  the 
 major_num 
???

we will always want the STARTING 

 major_num 
to be 0

and the 

 alloc_chrdev_region 
will return us the 
 dev_t dev

so we can extract the 

 major_num = MAJOR(dev); 

whenever we want!!!

 

 

Asked on September 30, 2019 in Linux.
Add Comment
1 Answer(s)

s

Answered on October 3, 2019.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.