drm-tests: atomictest: Cleanup drmModeAtomicGetCursor()/drmModeAtomicSetCursor()

run_testcase() does a drmModeAtomicGetCursor() and drmModeAtomicSetCursor()
for each testcase. But there are few testcases which do an additional
drmModeAtomicGetCursor() and drmModeAtomicSetCursor() like
test_primary_pageflip() and test_disable_primary().
Remove drmModeAtomicGetCursor() and drmModeAtomicSetCursor() from
individual testcases so that it is done only once from
run_testcase(). Also move the drmModeAtomicSetCursor() before commit(), which
passes the correct object id(of the next crtc id) to the kernel.

BUG=b:36575331
TEST=atomictest -all is successful on reef.

Change-Id: Ic0cc13df1f907a315eacb3d1ccd401af5f126723
Signed-off-by: Azhar Shaikh <azhar.shaikh@intel.com>
Reviewed-on: https://chromium-review.googlesource.com/607037
Tested-by: Dongseong Hwang <dongseong.hwang@intel.com>
Reviewed-by: Joe Kniss <djmk@google.com>
Reviewed-by: Dongseong Hwang <dongseong.hwang@intel.com>
1 file changed