Re: [PATCH] dev_t [2/3]

From: Greg KH (greg@kroah.com)
Date: Tue Mar 18 2003 - 18:56:42 EST


On Tue, Mar 18, 2003 at 11:02:21PM +0100, Andries.Brouwer@cwi.nl wrote:
> In order not to have to change all drivers, I did
>
> +int register_chrdev(unsigned int major, const char *name,
> + struct file_operations *fops)
> +{
> + return register_chrdev_region(major, 0, 256, name, fops);
> +}
>
> so that the old register_chrdev registers a single major
> and 256 minors. Later this can be changed (but see my letter
> to Al last week).

This is nice, thanks. We don't have to touch the char drivers now.

Ah, I wish we could change that function to be:
int register_chrdev_region(major, num_minors, name, fops)
if it wasn't for the tty drivers wanting to start their minor at 64.

Hm, wait, why can't we just do it that way and not change the tty core
to use the register_chrdev_region() call? It should still all work
properly, right? The tty core would ask for 256 minors, and split them
off the same way it currently does.

thanks,

greg k-h
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sun Mar 23 2003 - 22:00:25 EST