On Mon, Jan 13, 2014 at 03:52:16PM +0530, Tushar Behera wrote:
- if (driver->major) {
dev = MKDEV(driver->major, driver->minor_start);
error = register_chrdev_region(dev, driver->num, driver->name);
/* In case of error, fall back to dynamic allocation */
if (error < 0)
driver->major = 0;
- }
This probably needs to at least print a warning if the major number is being overridden.