• Home
  • Raw
  • Download

Lines Matching refs:major

36 	unsigned int major;  member
44 static inline int major_to_index(unsigned major) in major_to_index() argument
46 return major % CHRDEV_MAJOR_HASH_SIZE; in major_to_index()
57 if (cd->major == offset) in chrdev_show()
58 seq_printf(f, "%3d %s\n", cd->major, cd->name); in chrdev_show()
78 if (cd->major == i) in find_dynamic_major()
97 __register_chrdev_region(unsigned int major, unsigned int baseminor, in __register_chrdev_region() argument
104 if (major >= CHRDEV_MAJOR_MAX) { in __register_chrdev_region()
106 name, major, CHRDEV_MAJOR_MAX-1); in __register_chrdev_region()
122 if (major == 0) { in __register_chrdev_region()
129 major = ret; in __register_chrdev_region()
133 i = major_to_index(major); in __register_chrdev_region()
135 if (curr->major < major) in __register_chrdev_region()
138 if (curr->major > major) in __register_chrdev_region()
150 cd->major = major; in __register_chrdev_region()
172 __unregister_chrdev_region(unsigned major, unsigned baseminor, int minorct) in __unregister_chrdev_region() argument
175 int i = major_to_index(major); in __unregister_chrdev_region()
179 if ((*cp)->major == major && in __unregister_chrdev_region()
243 *dev = MKDEV(cd->major, cd->baseminor); in alloc_chrdev_region()
268 int __register_chrdev(unsigned int major, unsigned int baseminor, in __register_chrdev() argument
276 cd = __register_chrdev_region(major, baseminor, count, name); in __register_chrdev()
288 err = cdev_add(cdev, MKDEV(cd->major, baseminor), count); in __register_chrdev()
294 return major ? 0 : cd->major; in __register_chrdev()
298 kfree(__unregister_chrdev_region(cd->major, baseminor, count)); in __register_chrdev()
335 void __unregister_chrdev(unsigned int major, unsigned int baseminor, in __unregister_chrdev() argument
340 cd = __unregister_chrdev_region(major, baseminor, count); in __unregister_chrdev()