[Intel-gfx] [PATCH i-g-t 1/2] lib: Move __gem_context_create to common ioctl wrapper library.

Chris Wilson chris at chris-wilson.co.uk
Thu Oct 12 22:15:33 UTC 2017


Quoting Antonio Argenziano (2017-10-12 23:10:36)
> +/**
> + * gem_require_contexts:
> + * @fd: open i915 drm file descriptor
> + *
> + * This helper will automatically skip the test on platforms where context
> + * support is not available.
> + */
> +void gem_require_contexts(int fd)
> +{
> +       uint32_t ctx_id;
> +       igt_require(__gem_context_create(fd, &ctx_id) != -ENODEV);

Leaks on success.

Otherwise, perfect.
-Chris


More information about the Intel-gfx mailing list