summaryrefslogtreecommitdiff
path: root/include/linux/pipe_fs_i.h
diff options
context:
space:
mode:
authorManfred Spraul <manfred@colorfullife.com>2002-10-02 23:34:28 -0700
committerLinus Torvalds <torvalds@penguin.transmeta.com>2002-10-02 23:34:28 -0700
commitc33585c5a5458799af1de8009b71ffecb62371fa (patch)
treeb293babbef184106004440a97af7c9809dd6cb27 /include/linux/pipe_fs_i.h
parentd8ac8dd7546f9ba59dbae0c4a5393ad2a4a614b6 (diff)
[PATCH] pipe bugfix /cleanup
pipe_write contains a wakeup storm, 2 writers that write into the same fifo can wake each other up, and spend 100% cpu time with wakeup/schedule, without making any progress. The only regression I'm aware of is that $ dd if=/dev/zero | grep not_there will fail due to OOM, because grep does something like for(;;) { rlen = read(fd, buf, len); if (rlen == len) { len *= 2; buf = realloc(buf, len); } } if it operates on pipes, and due to the improved syscall merging, read will always return the maximum possible amount of data. But that's a grep bug, not a kernel problem.
Diffstat (limited to 'include/linux/pipe_fs_i.h')
-rw-r--r--include/linux/pipe_fs_i.h2
1 files changed, 0 insertions, 2 deletions
diff --git a/include/linux/pipe_fs_i.h b/include/linux/pipe_fs_i.h
index d6a7928a2866..407c0e0b3e84 100644
--- a/include/linux/pipe_fs_i.h
+++ b/include/linux/pipe_fs_i.h
@@ -9,7 +9,6 @@ struct pipe_inode_info {
unsigned int start;
unsigned int readers;
unsigned int writers;
- unsigned int waiting_readers;
unsigned int waiting_writers;
unsigned int r_counter;
unsigned int w_counter;
@@ -28,7 +27,6 @@ struct pipe_inode_info {
#define PIPE_LEN(inode) ((inode).i_pipe->len)
#define PIPE_READERS(inode) ((inode).i_pipe->readers)
#define PIPE_WRITERS(inode) ((inode).i_pipe->writers)
-#define PIPE_WAITING_READERS(inode) ((inode).i_pipe->waiting_readers)
#define PIPE_WAITING_WRITERS(inode) ((inode).i_pipe->waiting_writers)
#define PIPE_RCOUNTER(inode) ((inode).i_pipe->r_counter)
#define PIPE_WCOUNTER(inode) ((inode).i_pipe->w_counter)