lkml.org 
[lkml]   [1998]   [Jan]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: devlinks: an alternative to devfs
martin@mira.isdn.cs.tu-berlin.de (Martin von Loewis)  wrote on 09.01.98 in <199801090830.JAA00307@mira.isdn.cs.tu-berlin.de>:

> > Excuse my ignorance (I know that sure I am missing something), but why
> > don' t change in /usr/src/linux/include/linux/kdev_t.h from:
> >
> > typedef unsigned short kdev_t;
> >
> > to:
> >
> > typedef unsigned int kdev_t;
> >
> > and we will have magically space for 16 bit minor and major numbers. Then
> > we need to change MINORBITS to 16 and all others 8 to 16...
>
> Several reasons. For one, ext2 is not capable of storing 32 bit device
> numbers, at least not in the current definition of ext2. So you need
> to extend ext2.
>
> Furthermore, the system calls (most notable stat(2) and mknod(2) are
> not capable of passing 32 bits as device number, so you need new system
> calls.
>
> Next, the C library does not provide structure definitions for those
> system calls, nor does it call them. So you need a new C library.

Ok so far ...

> Finally, the applications allocating those structures on the stack
> don't know that the structure size changed. So you need to recompile all
> your applications.

Not if they are compiled for glibc. Glibc seems to show a 64 bit dev_t to
applications (see /usr/include/gnu/types.h).

The longer I look at glibc, the better it looks to me.


MfG Kai

\
 
 \ /
  Last update: 2005-03-22 13:41    [from the cache]
©2003-2011 Jasper Spaans