summaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
authorThierry Reding <thierry.reding@avionic-design.de>2013-02-13 16:08:33 +0100
committerThierry Reding <thierry.reding@avionic-design.de>2013-02-22 08:21:07 +0100
commit8cf1e9811471f2910fa38dc1b28e1789080ba961 (patch)
tree45b779f761fba928171b9d8a9c1928398737a5d5 /Documentation
parentc976cb37a95a8dcaf23d04d6487fbacc33d3c913 (diff)
drm: Add consistency check for page-flipping
Driver implementations of the drm_crtc's .page_flip() function are required to update the crtc->fb field on success to reflect that the new framebuffer is now in use. This is important to keep reference counting on the framebuffers balanced. While at it, document this requirement to keep others from falling into the same trap. Suggested-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Thierry Reding <thierry.reding@avionic-design.de> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/DocBook/drm.tmpl6
1 files changed, 6 insertions, 0 deletions
diff --git a/Documentation/DocBook/drm.tmpl b/Documentation/DocBook/drm.tmpl
index 51e1904ac4c..a6428ddfcfc 100644
--- a/Documentation/DocBook/drm.tmpl
+++ b/Documentation/DocBook/drm.tmpl
@@ -1161,6 +1161,12 @@ int max_width, max_height;</synopsis>
any new rendering to the frame buffer until the page flip completes.
</para>
<para>
+ If a page flip can be successfully scheduled the driver must set the
+ <code>drm_crtc-&lt;fb</code> field to the new framebuffer pointed to
+ by <code>fb</code>. This is important so that the reference counting
+ on framebuffers stays balanced.
+ </para>
+ <para>
If a page flip is already pending, the
<methodname>page_flip</methodname> operation must return
-<errorname>EBUSY</errorname>.