Skip to content

Commit

Permalink
OS-6275 lx pipe buffer is too small
Browse files Browse the repository at this point in the history
Reviewed by: Patrick Mooney <patrick.mooney@joyent.com>
Approved by: Patrick Mooney <patrick.mooney@joyent.com>
  • Loading branch information
jjelinek committed Aug 23, 2017
1 parent 32f7a45 commit 6ce43f2
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions usr/src/uts/common/brand/lx/syscall/lx_pipe.c
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,15 @@ lx_hd_pipe(intptr_t arg, int flags)
VERIFY((str = vp1->v_stream) != NULL);
(void) lx_pipe_setsz(str, LX_DEFAULT_PIPE_SIZE, B_TRUE);

/*
* Because we're using streams to increase the capacity of the pipe
* up to the default Linux capacity, we have to switch the pipe
* out of FIFOFAST mode and back to a normal stream. In fast mode
* the pipe capacity is limited to "Fifohiwat" which is a compile-time
* limit set to FIFOHIWAT.
*/
fifo_fastoff(VTOF(vp1));

/*
* Set the O_NONBLOCK flag if requested.
*/
Expand Down

0 comments on commit 6ce43f2

Please sign in to comment.