dev_t / udev_t confusion ?

M. Warner Losh imp at bsdimp.com
Wed Jun 9 18:32:24 GMT 2004


In message: <20040609142911.GA43972 at regency.nsu.ru>
            Alexey Dokuchaev <danfe at nsu.ru> writes:
: On Wed, Jun 09, 2004 at 01:16:30PM +0200, Poul-Henning Kamp wrote:
: > 
: > I have an item on my TODO list which says "fix dev_t / udev_t kernel
: > confusion before 5-STABLE ?".
: > 
: > The confusions is that in userland dev_t is an integer type which
: > encodes the major+minor number of a device, in the kernel it it a
: > pointer to "struct cdev" which represents the device to the kernel.
: 
: Go for solving the confusion, phk.  I'd sacrifice compatibility with
: other BSDs here in sake of coherency.

Actually, this makes us more compatible with other BSDs.  They never
went down this path.

However, it does add costs to those companies (like the one I work
for) that have to have drivers for both 4.x and 5.x.  These costs can
be managed, but it is a bit of a pain.  Luckily for me, it looks like
the conversion cost of other parts of the driver is high in comparison
to this change, which incrementally increases it.

I'm not sure that I like the churn this causes, but I'm not going to
fight it.

Warner


More information about the freebsd-arch mailing list