Re: [RFC][PATCH] 2/6 POSIX message queues
From: Sam Ravnborg
Date: Thu Feb 19 2004 - 13:53:33 EST
On Thu, Feb 19, 2004 at 02:53:31PM +0000, Christoph Hellwig wrote:
> > +#ifndef _LINUX_MQUEUE_H
> > +#define _LINUX_MQUEUE_H
> > +
> > +#define MQ_PRIO_MAX 32768
> > +
> > +typedef int mqd_t;
> > +
> > +struct mq_attr {
> > + long mq_flags; /* message queue flags */
> > + long mq_maxmsg; /* maximum number of messages */
> > + long mq_msgsize; /* maximum message size */
> > + long mq_curmsgs; /* number of messages currently queued */
> > +};
> > +
> > +#define NOTIFY_NONE 0
> > +#define NOTIFY_WOKENUP 1
> > +#define NOTIFY_REMOVED 2
> > +
> > +#ifdef __KERNEL__
> > +#include <linux/types.h>
> > +#include <linux/time.h>
>
> This looks like you want glibc to include it, please don't - add a copy
> without the kernel part to glibc instead.
In the previous threads about this the concept of kernel-only and shared
user and kernel headers has been seen as a good solution.
So a split in a kernel-only part, and another kernel+user part seems more
worth-while. And less error-prone.
Maybe something like:
mqueue.h for kernel-only
mqueue_abi.h for kernel+user
Sam
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/