Re: [kvm-unit-tests PATCH v6 06/10] s390x: css: stsch, enumeration test

Pierre Morel
2020-04-28T08:17:36Z

On 2020-04-27 15:06, Janosch Frank wrote:
> On 4/24/20 12:45 PM, Pierre Morel wrote:
>> First step for testing the channel subsystem is to enumerate the css and
>> retrieve the css devices.
>>
...snip...
>> diff --git a/lib/s390x/css.h b/lib/s390x/css.h
>> index bab0dd5..9417541 100644
>> --- a/lib/s390x/css.h
>> +++ b/lib/s390x/css.h
>> @@ -82,6 +82,7 @@ struct pmcw {
>> uint8_t chpid[8];
>> uint32_t flags2;
>> };
>> +#define PMCW_CHANNEL_TYPE(pmcw) (pmcw->flags2 >> 21)
>
> Why isn't this in the library patch?

OK

>> @@ -51,6 +52,7 @@ cflatobjs += lib/s390x/sclp-console.o
>> cflatobjs += lib/s390x/interrupt.o
>> cflatobjs += lib/s390x/mmu.o
>> cflatobjs += lib/s390x/smp.o
>> +cflatobjs += lib/s390x/css_dump.o
>
> Why isn't this in the library patch?

OK

>
...snip...
>> +#define SID_ONE 0x00010000
>
> Why isn't this in the library patch?

OK

>
...snip...
>> + if (!test_device_sid)
>> + test_device_sid = scn|SID_ONE;
>
> Give the pipe some space :)
>
>> + dev_found++;
>
> Newlines would make this more readable.

OK and yes.

>
>> + }
>> +out:
>
> We can report dev_found instead of 0/1 and a if/else
>
> report(dev_found,
> "Tested subchannels: %d, I/O subchannels: %d, I/O devices: %d",
> scn, scn_found, dev_found);

Yes, :)

Thanks,
Pierre

--
Pierre Morel
IBM Lab Boeblingen