summaryrefslogtreecommitdiff
path: root/lib/sw_sync.c
AgeCommit message (Collapse)Author
2018-07-12igt/pm_rpm: Pass NULL to require no extra module optionsChris Wilson
We use options!=NULL to determine if we should require the module to be reloaded and fail if we find it already loaded. In pm_rpm, we are only ensuring the MSR module is loaded, and only want default options. Fixes: 4dc2ce0e ("lib/kmod: Fail if the module is already loaded") Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: MichaƂ Winiarski <michal.winiarski@intel.com>
2017-12-27lib: Convert sw_sync to use sync_file uapi imported from the kernelChris Wilson
Similar to how we are now importing the drm uapi directly into igt, we also would like to have a copy of auxiliary uAPI such as sync_file. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
2017-09-08build: use HAVE_LIBGEN_H consistentlyDaniel Vetter
Also, we are _GNU_SOURCE, so simplify the conditions accordingly. The next patch will remove _GNU_SOURCE everywhere else. Reviewed-by: Eric Anholt <eric@anholt.net> Acked-by: Jani Nikula <jani.nikula@intel.com> Acked-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com> Acked-by: Petri Latvala <petri.latvala@intel.com> Acked-by: Daniel Stone <daniels@collabora.com> Acked-by: Radoslaw Szwichtenberg <radoslaw.szwichtenberg@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2017-07-24docs: Update documentation generation with missing entriesPaul Kocialkowski
This adds missing entries for documentation generation, both for tests and the API reference. The list of tests is made complete and ordered alphabetically, with modified descriptions for consistency. More files are added to the API reference, with a minimalistic description block added to them when it was missing. Signed-off-by: Paul Kocialkowski <paul.kocialkowski@linux.intel.com> Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
2017-03-25Replace more system("modprobe")Chris Wilson
As we have libkmod available, it is faster and safer than calling system(). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2017-01-04igt/gem_exec_fence: Check sync_file->status after the fence is signaledChris Wilson
After the fence is signaled, the status feed reports whether or not the request completed successfully. We set this to -EIO if a hang was detected. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2017-01-02lib: Mass conversion to to_user_pointer()Chris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-12-17lib/sw_sync: Rename sync_fence_create()Chris Wilson
It takes a sw_sync_timeline and returns a fence (it is a factory), so call it sw_sync_timeline_create_fence() for better self-documentation. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-12-17lib/sw_sync: Indicate that sync_merge() operates and create a sync_fenceChris Wilson
Improvements to self-documentating API that matches the rest of sw_sync. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-12-17lib/sw_sync: Bring sync_wait() API into lineChris Wilson
igt likes to return kernel-esque negative errno where we can, and indicate that we expect to operate on a sync_fence, otherwise it is merely a grandiose poll(). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-12-17lib/sw_sync: Provide compatiblity stubs for old headersChris Wilson
Common practice for igt when providing tests for new features in unreleased kernels is to include a complete set of uABI stubs. Lack of such compatability breaks compilation on current distributions' kernel headers. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-12-14lib/sw_sync: Add igt_require_sw_sync to enable skipping on no sw_sync supportRobert Foss
Add igt_require_sw_sync to provide tests to skip if sw_sync support isn't available on the host machine. Signed-off-by: Robert Foss <robert.foss@collabora.com> Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
2016-12-14lib/sw_sync: Add helper functions for managing synchronization primitivesRobert Foss
Base functions to help testing the Sync File Framework (explicit fencing mechanism ported from Android). These functions allow you to create, use and destroy timelines and fences. Signed-off-by: Robert Foss <robert.foss@collabora.com> Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Eric Engestrom <eric@engestrom.ch> Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>