Age | Commit message (Collapse) | Author |
|
Run the YUV <-> RGB conversion test with all four color spaces supported
by the VSP.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Add a test case to validate RGB <-> YUV conversion in the RPF and WPF.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Support configuring the color space when setting formats on subdev pads
and on video devices. As the VSP only cares about the encoding and
quantization, the colorspace and transfer function parameters are not
handled.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
The media-ctl utility names media bus codes by stripping the
MEDIA_BUS_FMT_ prefix from the kernel macro name. For a small set of
formats, alternative names are supported for historical reasons. Their
usage is discouraged, so use the canonical names in the tests.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Create a new vsp1_entity_set_format() function to set a pad format, and
use it through the code. This prepares for automating configuration of
colour space parameters.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
The RPF can perform color space conversion, converting between RGB and
YUV formats. Testing this feature requires specifying different formats
on the RPF input and output. Add a --midfmt argument to the
format_rpf_wpf() function to specify the RPF output format, and
propagate it through the pipeline up to the WPF input.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
When a test fail, it can be useful to inspect the frames input to the
RPFs. Save them along the frames output by the WPFs and the reference
frames.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Support YUV to RGB conversion, to emulate the RPF and WPF CSC. As for
RGB to YUV conversion, the coefficients have been reverse-engineered.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Merge the csc_matrix() function into image_convert_rgb_to_yuv() to avoid
unnecessary copies of the matrix.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Create an image_convert() function that encapsulates all format
conversion, and use it to replace direct calls to other converter
functions. This prepares for extending the supported conversions.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
To prepare for improvements to the format conversion code, split the
struct params into CSC parameters and packing parameters.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
RGB to YCbCr conversion is only used at the moment to generate images
for test cases that run fully YUV pipelines. The exact value of the RGB
to YCbCr conversion matrices hasn't mattered much so far. However, this
will change with introduction of tests that perform RGB to YCbCr
conversion. To achieve pixel-perfect match between the reference and
hardware frames, reference images need to be generated with the exact
method used by the VSP.
Replace the current coefficients by values obtained from
reverse-engineering of the RGB to YCbCr conversion performed by the
VSP1. Remove support for SMPTE240 and BT.2020, as the VSP hardware
supports BT.601 and BT.709 only.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Based on tests, the VSP1 hardware seems to round averaged chroma values
towards 0 when subsampling YUV formats. Replicate the same calculation
in gen-image.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
The reference images used by the test scripts are in PPM format, not
PNM. Use the correct file extension.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Meson makes cross compilation easier. Replace the make-based build
system with meson.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Python source code is typically indented with 4 spaces instead of tabs.
Update gen-lut.py accordingly.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Some skipped tests print a "skip" message, while other print "skipped".
This leads to some of them not being counted. Standardize on "skip".
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
|
|
If a test scripts outputs a line that doesn't match the
pass/fail/skipped criteria, the line is counted in the total number of
tests run, but not attributed to any individual category. This results
in a summary message such as
189 tests: 170 passed, 0 failed, 3 skipped
Fix it by ignoring those lines.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
|
|
YUV formats can be subsampled, which interact with cropping. Add a test
to verify that the VSP driver handles this correctly.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
|
|
When converting the input image to a subsampled YUV format, chroma
components are averaged horizontally to emulate the VSP internal
conversion to YUV444. If the image is subsequently cropped to emulate
the RPF cropping, the edge chroma values end up effectively taking into
account pixels outside of the crop rectangle. This doesn't match the
hardware mode of operation which crops the image when reading it through
DMA, before performing any other operation.
Fix this by cropping the image just after reading it, before format
conversion.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
|
|
vsp-unit-test-0026.sh is missing SPDX headers. Add them.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
|
|
Utilise the new monotonic timestamping tool to remove the manual parsing of
timestamps via /proc/timer_list which can only be read by root.
This also simplifies the processing required and contains all timestamping
actions within a single process space.
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Introduce a new utility which prefixes a monotonic timestamp rendered in the
same format as the kernel logs to all lines fed in through stdin.
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Python2 has now gone end-of-life and is discontinued.
Update the gen-lut utility to use python3 directly, converting xrange
usages to range, and using bytearray to store the tables and write them
directly removing the discontinued file object.
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Perform unbind-bind testing of the VSP devices to validate
successful removal of the drivers.
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Standardize on the usage of SPDX tags. No change in copyright is
included.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
|
|
Add SPDX tags to describe license and copyright information to all files
in the repository.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
|
|
All the changes required by the VSP test suite have been integrated in
the master branch of yavta. There is no need to depend on the vsp branch
anymore, remove the corresponding paragraph from the documentation.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
|
|
Validate that a 1xN stream can be read through the RPF and written
through the WPF.
The test framework does not currently support processing images where
the stride does not match the output width - so the testing is currently
limited to testing only the vertical direction in this aspect.
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
[Drop 1024x768 and 128x128 resolutions]
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Provide an initial test which can run as part of the test suite.
This test will report the platform and kernel version, along with
the identified paths of required utilities.
This will aid in ensuring that required tools are available on a
running platform - and report the kernel and platform details in
any test suite output for clarification of results.
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
[Don't depend on columns]
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Some of our tests set flipping and rotation controls, and the VSP
instance can be used again by later tests. If these controls are not
reset, then that operation is applied to later tests incorrectly causing
those tests to fail.
In an ideal world, tests should clean up after themselves, and leave the
system in a known state. However the world is not ideal and we would not
be able to guarantee any previous system state before a test was run
anyway. Therefore it is more effective to reset state at the beginning
of a test.
To repair this - reset all control values to their defaults at the start
of every test during test_init()
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
The suspend/resume test starts a run of 300 frames and suspends the
system one second later. On some SoCs (namely H3 ES2.0) the VSP
bandwidth is high enough to complete processing of 300 frames in less
than a second. The test thus suspends and resumes the system with the
VSP idle instead of running, defeating the purpose of the test.
Fix this by increasing the number of frames to process to 1000. The
frame count is now passed as an argument to the
test_extended_wpf_packing function to ease future changes.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
---
Changes since v1:
- Don't explicitly state at which frame suspend/resume is expected to
occur as that's device-dependent
- Compare the last three frames instead of just one
|
|
It can be useful to capture kernel log messages in test log files for
diagnostic purpose. Add a simple mechanism to do so by capturing the
full kernel log at the end of the test. The kernel log is cleared first
before starting the test to avoid capturing unrelated messages.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
Changes since v1:
- Don't clear the kernel log
|
|
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Tested-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
|
|
Reuse the BRU code, using the brx generic name to cover both BRU and
BRS.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Tested-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
|
|
Use the media device under test, not the default media0.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Tested-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
|
|
The killall command is provided by the psmisc package on debian based systems.
On other systems it should be built or added to the filesystem as appropriate.
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
On posix shells, only the '.' command is supported.
Even when running on a full bash shell, the file to source should be
either fully or locally qualified to avoid picking up a stray version
available in $PATH.
Fix both issues by swapping to the posix standard
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
The Gen3 VSP doesn't support HSV formats on the RPF or WPF. Skip the
test.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Test HGT histogram during video streaming.
Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
There are two kinds of histogram that can be generated, HGO and HGT. Let
the histogram compare function know which type it should use.
Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Add a new histogram type HGT to be able to compute HGT histogram frame
from RGB data. This is needed to test the HGT module together with the
HST module in the VSP pipeline to convert a image from RGB to HSV.
This also includes a new command line option to be able to specify the
user configuration of the HGT hue areas. This is needed to verify that the
HGT driver can operate with different hue area configurations.
Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
The VSP hardware can compute both 1D (HGO) and 2D (HGT) histograms. The
gen-image utility needs to know which histogram type it should generate
a reference frame for. Add a command line option which allows the user
to set the type.
Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
HSV is not written HSB.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
The string manipulations of the form ${VAR/search/replace} are not posix
compliant. Use string deletion, and append instead.
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
The tool is required to run tests vsp-unit-test-0021.sh and
vsp-unit-test-0022.sh.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Duplicate the functionality of vsp-unit-test-0020, to provide a longer
duration task for the hardware to run, whilst we load the system using the
'stress' utility.
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Duplicate the functionality of vsp-unit-test-0001, to provide a set of
work for the hardware to run, whilst we load the system using the
'stress' utility.
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
Provide a test to verify the hardware completes a functional test whilst
performing a suspend resume cycle in parallel. Make use of the
/sys/power/pm_test functionality provided by CONFIG_PM_DEBUG to perform
the testing
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|