Re: [PATCH] new system call mknod64

Andries.Brouwer
2003-04-21T21:31:10Z

Nice to see this discussion.

Linus says

> The question is only _where_ (not whether) we do the mapping. Right now we
> keep "dev_t" in the same format as we give back to user space, and thus we
> always map into that format internally. But we don't have to: we can have
> an internal format that is different from the one we show users.

and in fact the patches I have been giving out use kdev_t
as internal format, where you can think of kdev_t as
u64, or, if you prefer, as struct { u32 major, minor; }.

As I wrote a month or two ago, my favourite version is to
have register_region work in the kdev_t space, rather than
the dev_t space, since intervals in kdev_t space have a
direct interpretation in terms of major, minor.

Andries

(Both versions do not differ very much;
as far as I am concerned the choice is not very important,
but the kdev_t version is slightly cleaner.)

(As Al already remarked, device numbers do not play much of a role
internally. I removed i_dev. We still have i_rdev.)