lkml.org 
[lkml]   [2003]   [Jul]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] print_dev_t for 2.6.0-test1-mm
Greg KH <greg@kroah.com> wrote:
>
> > So we'll need to come up with some standardised way of presenting a dev_t
> > to the user. Presumably that will just be
> >
> > sprintf(buf, "%d:%d", major(dev), minor(dev));
> >
> > But if we do this, will it break your existing stuff?
>
> No, I don't think there are any users of udev right now :)
>
> I wouldn't mind the ':' being there, makes my life a bit easier, but for
> some reason Al Viro didn't want to do that a long time ago...
>
> If we put the ':' in there, it protects userspace from having to deal
> with different sized dev_t, so that really makes sense.

OK, I think I'll make it so and hope he doesn't notice ;)

The new dev_t encoding is a bit weird because we of course continue to
support the old 8:8 encoding. I think the rule is: "if the top 32-bits are
zero, it is 8:8, otherwise 32:32". We can express this nicely with
"%u:%u".

Now I need to go hunt down all those places where I added casts to unsigned
longs in printks. hrm.

-
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/

\
 
 \ /
  Last update: 2005-03-22 13:46    [W:0.087 / U:0.032 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site