summaryrefslogtreecommitdiff
path: root/tests/pm_backlight.c
AgeCommit message (Collapse)Author
2017-10-12tests/pm_backlight: Enable connected output to allow tests to succeed, v4.Maarten Lankhorst
If the connected output is disabled before this test is run, then the test will fail because actual_brightness stays at 0 instead of the value of the desired brightness. Fix this by reading intel_backlight/device for the output name, and enable that output at start of this test. Changes since v1: - Enable the connected output, instead of enabling all outputs. Changes since v2: - Set a dummy fb, just in case. Changes since v3: - Use igt_output_get_plane_type, not get_plane. Sample failure: IGT-Version: 1.20-g01c550a27986 (x86_64) (Linux: 4.14.0-rc3-fbconhax+ x86_64) (pm_backlight:1203) CRITICAL: Test assertion failure function test_and_verify, file pm_backlight.c:111: (pm_backlight:1203) CRITICAL: Failed assertion: ({ typeof(0) _a = (0); typeof(val - tolerance) _b = (val - tolerance); _a > _b ? _a : _b; }) <= result (pm_backlight:1203) CRITICAL: error: 91200 > 0 Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2016-05-03tests: limit pm_backlight actual brightness tolerance between 0 and maxJani Nikula
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-03tests: add context param to pm_backlight testsJani Nikula
We'll be adding more context for the subtests than just the max brightness. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-03tests: use igt_assert_lte to verify pm_backlight test resultsJani Nikula
Gives out better diagnostics than just igt_asssert. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2015-11-03tests: Run igt.cocciDaniel Stone
Signed-off-by: Daniel Stone <daniels@collabora.com>
2015-08-21lib: add a single include headerThomas Wood
Add a header that includes all the headers for the library. This allows reorganisation of the library without affecting programs using it and also simplifies the headers that need to be included to use the library. Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2015-08-14tests/pm_backlight: mark simple test as basicJesse Barnes
We should be able to adjust the backlight and observe changes in sysfs. Reviewed-by: Daniel Vetter <daniel@ffwll.ch> Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2015-05-28tests/pm_backlight: Add backlight testAntti Koskipaa
This is a basic sanity test of the backlight sysfs interface. v2: - Add jani's suggestion for immediate readback - Remove unused parameter from test_and_verify() - Add fade test Issue: VIZ-3377 Signed-off-by: Antti Koskipaa <antti.koskipaa@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Thomas Wood <thomas.wood@intel.com>