lib/kms: Add igt_display_try_commit2()
authorMatt Roper <matthew.d.roper@intel.com>
Mon, 30 Jun 2014 23:44:25 +0000 (16:44 -0700)
committerDamien Lespiau <damien.lespiau@intel.com>
Fri, 4 Jul 2014 11:04:12 +0000 (12:04 +0100)
commit82bc03f392a12e5d48818faa99b02f9b2ab54483
treeb71db16b41d421e552c585909212c800e8ee4122
parent1c25547d48296c3058c9e1cc45b533746144a230
lib/kms: Add igt_display_try_commit2()

Add a new public API that will attempt a display commit, but will return
an error code upon failure rather than failing the IGT test.  This is
intended to allow igt tests to verify that the expected error codes are
returned to userspace when invalid requests are issued.

Note that with non-atomic programming, a single commit operation has
several potential failure points internally; the first non-zero error
code encountered will be returned immediately and no further programming
will be performed by the commit.  It is the caller's responsibility to
return to a sane state.

Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
lib/igt_kms.c
lib/igt_kms.h