Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Enumerations | Functions
drm_crtc_helper.h File Reference
#include <linux/spinlock.h>
#include <linux/types.h>
#include <linux/idr.h>
#include <linux/fb.h>

Go to the source code of this file.

Data Structures

struct  drm_crtc_helper_funcs
 
struct  drm_encoder_helper_funcs
 
struct  drm_connector_helper_funcs
 

Enumerations

enum  mode_set_atomic { LEAVE_ATOMIC_MODE_SET, ENTER_ATOMIC_MODE_SET }
 

Functions

int drm_helper_probe_single_connector_modes (struct drm_connector *connector, uint32_t maxX, uint32_t maxY)
 
void drm_helper_disable_unused_functions (struct drm_device *dev)
 
int drm_crtc_helper_set_config (struct drm_mode_set *set)
 
bool drm_crtc_helper_set_mode (struct drm_crtc *crtc, struct drm_display_mode *mode, int x, int y, struct drm_framebuffer *old_fb)
 
bool drm_helper_crtc_in_use (struct drm_crtc *crtc)
 
bool drm_helper_encoder_in_use (struct drm_encoder *encoder)
 
void drm_helper_connector_dpms (struct drm_connector *connector, int mode)
 
int drm_helper_mode_fill_fb_struct (struct drm_framebuffer *fb, struct drm_mode_fb_cmd2 *mode_cmd)
 
int drm_helper_resume_force_mode (struct drm_device *dev)
 
void drm_kms_helper_poll_init (struct drm_device *dev)
 
void drm_kms_helper_poll_fini (struct drm_device *dev)
 
void drm_helper_hpd_irq_event (struct drm_device *dev)
 
void drm_kms_helper_poll_disable (struct drm_device *dev)
 
void drm_kms_helper_poll_enable (struct drm_device *dev)
 

Enumeration Type Documentation

Enumerator:
LEAVE_ATOMIC_MODE_SET 
ENTER_ATOMIC_MODE_SET 

Definition at line 42 of file drm_crtc_helper.h.

Function Documentation

int drm_crtc_helper_set_config ( struct drm_mode_set set)

drm_crtc_helper_set_config - set a new config from userspace : CRTC to setup : user provided configuration : new mode to set : set of connectors for the new config : new framebuffer

LOCKING: Caller must hold mode config lock.

Setup a new configuration, provided by the user in , and enable it.

RETURNS: Zero. (FIXME)

Definition at line 509 of file drm_crtc_helper.c.

bool drm_crtc_helper_set_mode ( struct drm_crtc crtc,
struct drm_display_mode mode,
int  x,
int  y,
struct drm_framebuffer old_fb 
)

drm_crtc_set_mode - set a mode : CRTC to program : mode to use : width of mode : height of mode

LOCKING: Caller must hold mode config lock.

Try to set on . Give and its associated connectors a chance to fixup or reject the mode prior to trying to set it.

RETURNS: True if the mode was set successfully, or false otherwise.

Definition at line 343 of file drm_crtc_helper.c.

void drm_helper_connector_dpms ( struct drm_connector connector,
int  mode 
)

drm_helper_connector_dpms affected connector DPMS mode

Calls the low-level connector DPMS function, then calls appropriate encoder and crtc DPMS functions as well

Definition at line 810 of file drm_crtc_helper.c.

bool drm_helper_crtc_in_use ( struct drm_crtc crtc)

drm_helper_crtc_in_use - check if a given CRTC is in a mode_config : CRTC to check

LOCKING: Caller must hold mode config lock.

Walk 's DRM device's mode_config and see if it's in use.

RETURNS: True if is part of the mode_config, false otherwise.

Definition at line 207 of file drm_crtc_helper.c.

void drm_helper_disable_unused_functions ( struct drm_device dev)

drm_helper_disable_unused_functions - disable unused objects : DRM device

LOCKING: Caller must hold mode config lock.

If an connector or CRTC isn't part of 's mode_config, it can be disabled by calling its dpms function, which should power it off.

Definition at line 240 of file drm_crtc_helper.c.

bool drm_helper_encoder_in_use ( struct drm_encoder encoder)

drm_helper_encoder_in_use - check if a given encoder is in use : encoder to check

LOCKING: Caller must hold mode config lock.

Walk 's DRM device's mode_config and see if it's in use.

RETURNS: True if is part of the mode_config, false otherwise.

Definition at line 184 of file drm_crtc_helper.c.

void drm_helper_hpd_irq_event ( struct drm_device dev)

Definition at line 1015 of file drm_crtc_helper.c.

int drm_helper_mode_fill_fb_struct ( struct drm_framebuffer fb,
struct drm_mode_fb_cmd2 mode_cmd 
)

Definition at line 858 of file drm_crtc_helper.c.

int drm_helper_probe_single_connector_modes ( struct drm_connector connector,
uint32_t  maxX,
uint32_t  maxY 
)

drm_helper_probe_single_connector_modes - get complete set of display modes : DRM device : max width for modes : max height for modes

LOCKING: Caller must hold mode config lock.

Based on 's mode_config layout, scan all the connectors and try to detect modes on them. Modes will first be added to the connector's probed_modes list, then culled (based on validity and the , parameters) and put into the normal modes list.

Intended to be used either at bootup time or when major configuration changes have occurred.

FIXME: take into account monitor limits

RETURNS: Number of modes found on .

Definition at line 87 of file drm_crtc_helper.c.

int drm_helper_resume_force_mode ( struct drm_device dev)

Definition at line 877 of file drm_crtc_helper.c.

void drm_kms_helper_poll_disable ( struct drm_device dev)

Definition at line 974 of file drm_crtc_helper.c.

void drm_kms_helper_poll_enable ( struct drm_device dev)

Definition at line 982 of file drm_crtc_helper.c.

void drm_kms_helper_poll_fini ( struct drm_device dev)

Definition at line 1009 of file drm_crtc_helper.c.

void drm_kms_helper_poll_init ( struct drm_device dev)

Definition at line 1000 of file drm_crtc_helper.c.