[CRIU] [PATCH 0/3] zdtm: take care of short reads
Andrei Vagin
avagin at virtuozzo.com
Sat Dec 2 04:12:16 MSK 2017
I applied this series only for fifo tests.
It was another reason why we saw short-reads:
[PATCH 2/2] pipe: dump all data from a pipe
On Thu, Nov 30, 2017 at 01:46:17PM +0200, Mike Rapoport wrote:
> Hi,
>
> On loaded systems read may return less data then requested and it's
> perfectly Ok. However, some zdtm tests expect that large chunks of data
> will be read in one go and fail when short reads happen.
>
> These patches try to fix it by using {read,write}_data helpers that do not
> treat incomplete IO operations as error.
>
> I've updated some of the tests to use these new helpers, but I might have
> miss something.
>
> The last patch is not strictly related, it's just when I was looking for
> read() calls I've found out that several socket tests duplicate some code.
>
> Mike Rapoport (3):
> zdtm: lib: add {read,write}_data helpers
> zdtm: use {read,write}_data where applicable
> zdtm: move common code to the library
>
> test/zdtm/lib/streamutil.c | 98 ++++++++++++++++++++++++++++++++
> test/zdtm/lib/zdtmtst.h | 6 +-
> test/zdtm/static/deleted_unix_sock.c | 4 +-
> test/zdtm/static/fifo-ghost.c | 7 +--
> test/zdtm/static/fifo.c | 7 +--
> test/zdtm/static/fifo_ro.c | 7 +--
> test/zdtm/static/file_attr.c | 4 +-
> test/zdtm/static/overmount_sock.c | 4 +-
> test/zdtm/static/socket-tcp-close-wait.c | 68 +---------------------
> test/zdtm/static/socket-tcp-closing.c | 67 +---------------------
> test/zdtm/static/socket-tcp-fin-wait1.c | 65 +--------------------
> test/zdtm/static/socket-tcp.c | 29 ----------
> test/zdtm/static/socket-tcpbuf.c | 62 --------------------
> test/zdtm/static/unlink_fstat00.c | 4 +-
> test/zdtm/static/write_read00.c | 4 +-
> test/zdtm/static/write_read01.c | 6 +-
> test/zdtm/static/write_read02.c | 8 +--
> test/zdtm/static/write_read10.c | 4 +-
> 18 files changed, 133 insertions(+), 321 deletions(-)
>
> --
> 2.7.4
>
More information about the CRIU
mailing list