On Thu, Apr 04, 2002 at 03:04:17PM +1000, Anthony Towns wrote:
> The kernel doesn't change ioctl numbers; they're actually competent at
> maintaining their interfaces. OTOH, they don't consider their headers
> such an interface, and they're happy to have them break randomly or not
> work from userspace at all or anything.
> 
> What we really should have is a nice low-level C library that encapsulates
> such things and lets anyone use it...

Fine and dandy, but what do I do in the meantime?  I can guard each of
the ioctl #defines with an #ifndef, but there's also a typedef thrown
into the mix.  I can't exactly do this:

try {
        typedef struct {
          int context;
          unsigned int offset;
          unsigned int size;
          unsigned int free;
        } drm_sis_mem_t;
} except redefinitionException {
        /* oh, that's all right, it's already defined */
}

It's because of this that I continue to feel that kernel interfaces are
best defined by the kernel.

If the kernel headers aren't an interface, why do they exist?  There
appears to be a very large philosophical gulf here.  The fact that the
Linux kernel guys may long for nice low-level C libraries that
encapsulate such things doesn't mean they exist.  Is this a side-effect
of some sort of "real men don't program in userspace" dogma?

-- 
G. Branden Robinson                |          Measure with micrometer,
Debian GNU/Linux                   |          mark with chalk,
[EMAIL PROTECTED]                 |          cut with axe,
http://people.debian.org/~branden/ |          hope like hell.

Attachment: pgpNYjTRYa7Kg.pgp
Description: PGP signature

Reply via email to