Log domains can be used to identify the source of log messages, such as
the test being run or the helper library.
v2: Add separate domains for different parts of the helper library and
use an empty default domain for applications.
Expand the log output to include the process name and the log level
of the message in addition to the domain and pid.
Print the expanded message only for warning and debug messages.
v3: check for glibc before using program_invocation_short_name
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
Use images with a smaller file size, created by saving the left and
right stereo output of glxgears.
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
The valid pipe/connector combo check was lost in
commit 57259d714d3fe1170cf931af72648219856a9918
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date: Mon Nov 24 16:08:32 2014 +0100
lib/igt_debugfs: Don't setup crc in _new
Restore it to make the test again useful on CHV.
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Report SKIP only if none of the pipe/connector combos worked, instead of
trying to report for each pipe separately.
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
On CHV we sometimes see not just one but two bad CRCs. No real idea
what would cause that, but let's just throw away the second CRC as
well to gain some stability for the tests.
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Aim the dummy load to the current back buffer instead if the front
buffer. Assuming the idea is to get the next flip to be stuck behind
the dummy load?
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Try to tune the dummy load to ~1 second. The calibration happens the
first time dummy load is generated.
v2: Actually do the number of ops intended and
calibrate to 1 second and not 2
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Make the dummy load independent of the display resolution by using a
two fixed size dummy bos to generate the load. As a final step do
another copy from one of the dummy bos to the fb to make sure there's
a dependency between the dummy load and any subsequent operation on
the fb.
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
swap() will swap its two arguments while keeping the required
tmp variable hidden. Makes for neater code.
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
When setting the calculated middle frequency value the test assumes that
the HW/kernel rounds this value according to a 50MHz step value. This is
not so at least on VLV/CHV, on my B0 BYT-M for example this step value
is 22MHz, so there the test will fail.
To fix this get the nearest supported value by setting the target
frequency as a min or max frequency and read it back. The kernel will
round the returned value to the nearest supported.
v2:
- remove the 50MHz rounding that was done for non-VLV platforms, the new
way of rounding should provide the correct value for all platforms
(Ville)
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Imre Deak <imre.deak@intel.com>
When changing the sysfs GT min/max frequencies, the kernel won't
explicitly change the current frequency, unless it becomes out of bound
based on the new min/max values. The test happens to work on non-VLV
platforms because on those the kernel resets the current frequency
unconditionally (to adjust the RPS interrupt mask as a side-effect) and
that will lead to an RPS interrupt setting the minimum frequency.
To fix this load the GPU after decreasing the min frequency and before
checking the current frequency. This should set the current frequency to
the minimum.
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Imre Deak <imre.deak@intel.com>
At least on VLV when forcing a new GT frequency by writing to the
min/max freq sysfs entries the kernel doesn't wait until the new
frequency settles, so the subsequent readback check might fail. To fix
this wait until the current frequency is between the min/max values
using a 10ms timeout.
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Imre Deak <imre.deak@intel.com>
As we require a pipe enabled to generate vblanks, the first step is to
then to check that pipe 0 is active or else skip the test.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Check that the more obvious userspace error conditions are handled by
the kernel, ideally without loss of data. These include nonblocking
waits, passing invalid buffers and passing buffers of the incorrect
length.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Here is a cheap way for this test to give consistent results. This
doesn't change the usefulness of this test, hopefully.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=85270
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
gem_gpgpu_fill was added in commit 4ec8479 (tests: Add gem_gpgpu_fill),
but wasn't added to .gitignore.
Cc: Zhenyu Wang <zhenyuw@linux.intel.com>
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
Install the exit handler to reset connector states whenever
kmstest_force_connector is called, so that the connector states are
always reset even if a test fails.
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
Enclose the test description in cdata tags since the test descriptions
come from the tests themselves and may not be escaped for use in xml.
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
This is simply a copy of gem_media_fill but using new
GPGPU fill operation.
v2: Use general fill func pointer.
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
This is to add fill operation using GPGPU pipeline which is similar to
current media fill. This can be used to simply verify GPGPU pipeline
and help to enable it on newer HW, currently it works on Gen7 only and
will add support on later platform.
Now this sets very simply thread group dispatch for one thread per
thread group on SIMD16 dispatch. So the fill shader just uses thread
group ID for buffer offset.
v2: No new fill func typedef but adapt to igt_fillfunc_t.
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
This test will not run on Android as the coreu service
remains running even after the android system is stopped.
Coreu is a client of drm and when the test finds this it
fails an assert.
Coreu is started by the init process and there is no
tidy, non invasive way to stop it (init just restarts it).
Coreu isn't doing anything and would not be expected to
interfere with this test. In addition, all the other
igt tests just rely on the user/test script to ensure
that there are no other drm clients, so this test can
do the same. On Android we must rely on coreu being
dormant when this test runs.
Signed-off-by: Tim Gore <tim.gore@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
kms_pwrite_crc was recently added and requires cairo, so
add this to the list of tests to exclude if cairo is not
avaiable
Signed-off-by: Tim Gore <tim.gore@intel.com>
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
If we wait for one vblank, we may end up returning almost immediately,
so trying to assert anything but >0 about the minimum duration is
bogus.
Instead wait for two vblanks and then we can assert that we should have
be blocked for at least one frame. And move the upper bound to a little
over two frames to match.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=79050
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
gem_ring_sync_copy uses a lot of memory and gets OOM killed on smaller
systems (eg android devices). Most of the allocation is for "busy work"
to keep the render rings busy and for this we can just re-use the same
few buffers over and over. This enables the test to be run on low end
devices.
Reviewed-by: Damien Lespiau <damien.lespiau@intel.com>
Signed-off-by: Tim Gore <tim.gore@intel.com>
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>