[LTP] [PATCH v2] read_all: give more time to wait children finish read action

Li Wang liwang@redhat.com
Thu Apr 12 05:01:26 CEST 2018


Richard Palethorpe <rpalethorpe@suse.de> wrote:

>
> >  #define MAX_DISPLAY 40
> > +#define MICROSECOND 1
>
> Not necessary.
>
​
Ok.
​


> >
> >       for (i = 0; i < worker_count; i++) {
> > -             stop_attempts = 0xffff;
> >               if (workers[i].q) {
>
> Maybe change this to:
> if (!workers[i].q)
>    continue;
>
> To avoid a level of indentation.
>

​Sounds good.
​

> +                     tst_brk(TBROK,
> > +                             "Attempts %d times but still failed to
> push %s",
>                                  ^ Attempted
>

​Good catch.
​


>
> > +                             push_attempts, path);
> >               }
> >       }
> >  }
>
> Maybe you could put the "if (delaly < SECOND) ..." into a function?
>

​Firstly, I was thinking to take use of my new macros, but
consider that have not been reviewed. So I tend to keep
it as original, then replace them entirely after ltp gets
a generic loop functionality in library.



>
> Otherwise this looks good to me. There are some other things I want to
> change on this test, but we can leave those for another patch.
>

​Thanks, Patch v3 is coming...
​


-- 
Li Wang
liwang@redhat.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linux.it/pipermail/ltp/attachments/20180412/49b93e3a/attachment-0001.html>


More information about the ltp mailing list