XenevaOS
Loading...
Searching...
No Matches
Public Attributes | List of all members
drm_mode_config_helper_funcs Struct Reference

#include <drm_modeset_helper_vtables.h>

Public Attributes

void(* atomic_commit_tail )(struct drm_atomic_commit *state)
 
int(* atomic_commit_setup )(struct drm_atomic_commit *state)
 

Detailed Description

struct drm_mode_config_helper_funcs - global modeset helper operations

These helper functions are used by the atomic helpers.

Member Data Documentation

◆ atomic_commit_setup

int(* drm_mode_config_helper_funcs::atomic_commit_setup) (struct drm_atomic_commit *state)

@atomic_commit_setup:

This hook is used by the default atomic_commit() hook implemented in drm_atomic_helper_commit() together with the nonblocking helpers (see drm_atomic_helper_setup_commit()) to extend the DRM commit setup. It is not used by the atomic helpers.

This function is called at the end of drm_atomic_helper_setup_commit(), so once the commit has been properly setup across the generic DRM object states. It allows drivers to do some additional commit tracking that isn't related to a CRTC, plane or connector, tracked in a &drm_private_obj structure.

Note that the documentation of &drm_private_obj has more details on how one should implement this.

This hook is optional.

◆ atomic_commit_tail

void(* drm_mode_config_helper_funcs::atomic_commit_tail) (struct drm_atomic_commit *state)

@atomic_commit_tail:

This hook is used by the default atomic_commit() hook implemented in drm_atomic_helper_commit() together with the nonblocking commit helpers (see drm_atomic_helper_setup_commit() for a starting point) to implement blocking and nonblocking commits easily. It is not used by the atomic helpers

This function is called when the new atomic state has already been swapped into the various state pointers. The passed in state therefore contains copies of the old/previous state. This hook should commit the new state into hardware. Note that the helpers have already waited for preceding atomic commits and fences, but drivers can add more waiting calls at the start of their implementation, e.g. to wait for driver-internal request for implicit syncing, before starting to commit the update to the hardware.

After the atomic update is committed to the hardware this hook needs to call drm_atomic_helper_commit_hw_done(). Then wait for the update to be executed by the hardware, for example using drm_atomic_helper_wait_for_vblanks() or drm_atomic_helper_wait_for_flip_done(), and then clean up the old framebuffers using drm_atomic_helper_cleanup_planes().

When disabling a CRTC this hook must stall for the commit to complete. Vblank waits don't work on disabled CRTC, hence the core can't take care of this. And it also can't rely on the vblank event, since that can be signalled already when the screen shows black, which can happen much earlier than the last hardware access needed to shut off the display pipeline completely.

This hook is optional, the default implementation is drm_atomic_helper_commit_tail().


The documentation for this struct was generated from the following file: