CHROMIUM: drm/i915: Wait for vblank after disabling cursor

The cursor disable write is latched on vsync but if we do a modeset
before that happens the write seems to be discarded and the cursor
stays on. The CURCNTL register will still read back 0 as if the write
took, but underlying hardware didn't change. We don't disable the
cursor often, so we can just force the pre-GEN9 path for cursor
that waits for vblank.

BUG=b:138431568
TEST=Toggle primary/extended display as described in bug

Cherry-picked from chromeos-4.4

Conflicts:
	Nathan: adapted this from chromeos-4.4 in chromeos-4.19 context:
	drivers/gpu/drm/i915/intel_display.c

Change-Id: Ia9f8bddfe5c3b65ebe457dff1755547751ef0f47
Signed-off-by: Kristian H. Kristensen <hoegsberg@chromium.org>
Signed-off-by: Nathan Ciobanu <nathan.d.ciobanu@intel.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/kernel/+/1721195
Tested-by: Sushma Venkatesh Reddy <sushma.venkatesh.reddy@intel.com>
Tested-by: Nelson Ye <nelson_ye@compal.corp-partner.google.com>
Tested-by: Lucien Kao <lucien_kao@compal.corp-partner.google.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Commit-Queue: Simon Glass <sjg@chromium.org>
(cherry picked from commit 17dd32f676b1923e3045a1341253754b6fcd4ee1)
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/kernel/+/1722636
1 file changed