[LTP] [PATCH 1/4] syscalls/migrate_pages02: convert to newlib

Jan Stancek jstancek@redhat.com
Mon Nov 19 12:44:26 CET 2018


----- Original Message -----
> 
> 
> ----- Original Message -----
> > Jan Stancek <jstancek@redhat.com> wrote:
> > 
> > >
> > >                 /* wait until child1 is ready on node1, then migrate and
> > >                  * signal to check current node */
> > > -               if (read(child1_ready[0], &tmp, 1) != 1)
> > > -                       tst_brkm(TBROK | TERRNO, NULL, "read #2 failed");
> > > +               TST_CHECKPOINT_WAIT(1);
> > >
> > 
> > Just curious why not start from 0? TST_CHECKPOINT_WAIT(0)
> 
> No special reason, I just had in my mind child1 and child2.
> 
> > 
> > -       tst_record_childstatus(NULL, child2);
> > > -       tst_record_childstatus(NULL, child1);
> > > +       SAFE_WAITPID(child1, &status, 0);
> > > +       SAFE_WAITPID(child2, &status, 0);
> > >
> > 
> > Maybe we could set &wstatus as a NULL? we don't inspect the status
> > information after its children terminates so why we store it into &status?
> 
> Good point, the status is not needed, since results from children
> are propagated automatically.
> 
> > Beside that two questions, patch set looks good to me.
> 
> Thanks for review,
> Jan

Pushed with changes from Li's comments.

Regards,
Jan



More information about the ltp mailing list