[Intel-gfx] [PATCH i-g-t v3 1/2] tests: Add blob-property test

Thomas Wood thomas.wood at intel.com
Thu Sep 10 06:37:46 PDT 2015


On 10 September 2015 at 14:02, Daniel Stone <daniel at fooishbar.org> wrote:
> Hi Thomas,
>
> On 10 September 2015 at 13:31, Thomas Wood <thomas.wood at intel.com> wrote:
>> On 10 September 2015 at 07:06, Daniel Stone <daniel at fooishbar.org> wrote:
>>> On 10 September 2015 at 06:57, Daniel Stone <daniels at collabora.com> wrote:
>>>> Exercises the new blob-creation ioctl, testing lifetimes and behaviour
>>>> of user-created blobs, as well as exercising all the invariant
>>>> conditions we guarantee from modes exposed as blob properties.
>>
>> Would be good to skip on older kernels that don't have this feature.
>
> That should already happen, but I'll double-check, if I can dig up a
> suitably old kernel.

Although there is an igt_require on the create_prop return value,
do_ioctl will fail the test if the ioctl call failed. There is also an
additional call to igt_require on the same value in test_core, which
should probably be an igt_assert.

Also, should test_basic be a subtest of its own, rather than part of
the test fixture?


>
>> The required libdrm version also needs updating (or adding local
>> defines of the new ioctl).
>
> Yes, good catch.
>
>> The use of igt_assert_eq/neq rather than plain igt_assert would
>> produce some better error messages by printing the expected and actual
>> values, but it looks like the meaning of the return values being
>> tested isn't consistent (i.e. sometimes errno values, sometimes not).
>
> OK, thanks - I'll go back and check these out. Is there a preferred
> style, or is it just consistency?

igt_assert_eq/neq will print the expected value and the actual value
being tested, which is only useful if the meaning of the value is
consistent (e.g. an errno value). This is simply to help identify any
obvious problems quicker without having to re-run the application with
a debugger attached.


>
>>> Sorry for spamming this; apparently either myself or fd.o are having
>>> some mail issues.
>>>
>>> In the meantime, the basic atomic tests can be found at:
>>> https://git.collabora.com/cgit/user/daniels/intel-gpu-tools.git/commit/?h=wip/atomic-blob&id=11bf34a2a
>>
>> I guess that was going to be patch 2/2?
>
> Still is, hopefully. :)
>
> Cheers,
> Daniel
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx


More information about the Intel-gfx mailing list