'\" t .\" Title: drm_vblank_pre_modeset .\" Author: .\" Generator: DocBook XSL Stylesheets v1.78.1 .\" Date: May 2018 .\" Manual: DRM Core .\" Source: Kernel Hackers Manual 3.16.56 .\" Language: English .\" .TH "DRM_VBLANK_PRE_MODES" "9" "May 2018" "Kernel Hackers Manual 3\&.16\&" "DRM Core" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" drm_vblank_pre_modeset \- account for vblanks across mode sets .SH "SYNOPSIS" .HP \w'void\ drm_vblank_pre_modeset('u .BI "void drm_vblank_pre_modeset(struct\ drm_device\ *\ " "dev" ", int\ " "crtc" ");" .SH "ARGUMENTS" .PP \fIdev\fR .RS 4 DRM device .RE .PP \fIcrtc\fR .RS 4 CRTC in question .RE .SH "DESCRIPTION" .PP Account for vblank events across mode setting events, which will likely reset the hardware frame counter\&. .PP This is done by grabbing a temporary vblank reference to ensure that the vblank interrupt keeps running across the modeset sequence\&. With this the software\-side vblank frame counting will ensure that there are no jumps or discontinuities\&. .PP Unfortunately this approach is racy and also doesn\*(Aqt work when the vblank interrupt stops running, e\&.g\&. across system suspend resume\&. It is therefore highly recommended that drivers use the newer \fBdrm_vblank_off\fR and \fBdrm_vblank_on\fR instead\&. \fBdrm_vblank_pre_modeset\fR only works correctly when using \(lqcooked\(rq software vblank frame counters and not relying on any hardware counters\&. .PP Drivers must call \fBdrm_vblank_post_modeset\fR when re\-enabling the same crtc again\&. .SH "AUTHORS" .PP \fBJesse Barnes\fR <\&jesse.barnes@intel.com\&> .br Intel Corporation, .RS 4 Initial version .RE .PP \fBLaurent Pinchart\fR <\&laurent.pinchart@ideasonboard.com\&> .br Ideas on board SPRL, .RS 4 Driver internals .RE .PP \fBDaniel Vetter\fR <\&daniel.vetter@ffwll.ch\&> .br Intel Corporation, .RS 4 Contributions all over the place .RE .SH "COPYRIGHT" .br