On 16.01.20 13:05, Janosch Frank wrote: > Let's remove a lot of badly formatted code by introducing the > wait_for_flag() function. > > Also let's remove some stray spaces. > > Signed-off-by: Janosch Frank <frankja@xxxxxxxxxxxxx> > Reviewed-by: Thomas Huth <thuth@xxxxxxxxxx> > Reviewed-by: Cornelia Huck <cohuck@xxxxxxxxxx> > --- > s390x/smp.c | 42 ++++++++++++++++++++++++------------------ > 1 file changed, 24 insertions(+), 18 deletions(-) > > diff --git a/s390x/smp.c b/s390x/smp.c > index ab7e46c..02204fd 100644 > --- a/s390x/smp.c > +++ b/s390x/smp.c > @@ -22,6 +22,13 @@ > > static int testflag = 0; > > +static void wait_for_flag(void) > +{ > + while (!testflag) { > + mb(); > + } > +} > + > static void cpu_loop(void) > { > for (;;) {} > @@ -37,13 +44,11 @@ static void test_func(void) > static void test_start(void) > { > struct psw psw; > - psw.mask = extract_psw_mask(); > + psw.mask = extract_psw_mask(); > psw.addr = (unsigned long)test_func; > > smp_cpu_setup(1, psw); > - while (!testflag) { > - mb(); > - } > + wait_for_flag(); > report(1, "start"); > } > > @@ -98,6 +103,7 @@ static void test_store_status(void) > report(1, "status written"); > free_pages(status, PAGE_SIZE * 2); > report_prefix_pop(); > + smp_cpu_stop(1); This hunk does not seem to belong into this patch. Apart from that, looks good to me. -- Thanks, David / dhildenb