[Intel-gfx] [PATCH igt 1/2] igt/perf_pmu: Clear errno in between invalid atrr tests

Tvrtko Ursulin tvrtko.ursulin at linux.intel.com
Wed Nov 22 20:48:06 UTC 2017


On 22/11/2017 19:00, Chris Wilson wrote:
> Reset the errno after testing each invalid attr so that it is carried
> over on a false positive.
> 
> Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
> Cc: Chris Wilson <chris at chris-wilson.co.uk>
> ---
>   tests/perf_pmu.c | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/tests/perf_pmu.c b/tests/perf_pmu.c
> index e2d2caba..bcb90c84 100644
> --- a/tests/perf_pmu.c
> +++ b/tests/perf_pmu.c
> @@ -689,6 +689,7 @@ do { \
>   	attr.config = I915_PMU_ENGINE_BUSY(I915_ENGINE_CLASS_RENDER, 0); \
>   	attr.type = i915_type_id(); \
>   	igt_assert(attr.type != 0); \
> +	errno = 0; \
>   } while(0)
>   
>   	ATTR_INIT();
> 

Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin at intel.com>

Regards,

Tvrtko


More information about the Intel-gfx mailing list