Re: limits / PIPE_BUF?

From: Arjan van de Ven
Date: Thu May 04 2006 - 02:58:01 EST


On Wed, 2006-05-03 at 22:55 -0700, Vadim Lobanov wrote:
> Hi,
>
> I was reading through the include/linux/limits.h file in order to
> generate a cleanup patch for it -- a large number of #defines within
> that file are no longer being used, as I surmise that they are simply
> remnants of earlier implementations.
>
> A snippet from include/linux/limits.h:
> #define PIPE_BUF 4096 /* # bytes in atomic write to a pipe */
>
> PIPE_BUF is a bit of an oddity. It is defined there, then redefined in
> the arm header files, even though those header files are never included
> anywhere. Also, PIPE_BUF is never referenced by name in any of the Linux
> code. And yet, it is still being mentioned in some Big And Scary
> Warnings (tm): fs/autofs4/waitq.c or include/linux/pipe_fs_i.h, for
> example.

it's for userland to tell it what the size of the atomic pipe operations
we can do is.


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