Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
drm_encoder_slave.h File Reference
#include <drm/drmP.h>
#include <drm/drm_crtc.h>

Go to the source code of this file.

Data Structures

struct  drm_encoder_slave_funcs
struct  drm_encoder_slave
struct  drm_i2c_encoder_driver


#define to_encoder_slave(x)   container_of((x), struct drm_encoder_slave, base)
#define to_drm_i2c_encoder_driver(x)


int drm_i2c_encoder_init (struct drm_device *dev, struct drm_encoder_slave *encoder, struct i2c_adapter *adap, const struct i2c_board_info *info)
void drm_i2c_encoder_destroy (struct drm_encoder *encoder)

Macro Definition Documentation

#define to_drm_i2c_encoder_driver (   x)

Definition at line 128 of file drm_encoder_slave.h.

#define to_encoder_slave (   x)    container_of((x), struct drm_encoder_slave, base)

Definition at line 102 of file drm_encoder_slave.h.

Function Documentation

void drm_i2c_encoder_destroy ( struct drm_encoder drm_encoder)

drm_i2c_encoder_destroy - Unregister the I2C device backing an encoder : Encoder to be unregistered.

This should be called from the method of an I2C slave encoder driver once I2C access is no longer needed.

Definition at line 114 of file drm_encoder_slave.c.

int drm_i2c_encoder_init ( struct drm_device dev,
struct drm_encoder_slave encoder,
struct i2c_adapter adap,
const struct i2c_board_info info 

drm_i2c_encoder_init - Initialize an I2C slave encoder : DRM device. : Encoder to be attached to the I2C device. You aren't required to have called drm_encoder_init() before. : I2C adapter that will be used to communicate with the device. : Information that will be used to create the I2C device. Required fields are and .

Create an I2C device on the specified bus (the module containing its driver is transparently loaded) and attach it to the specified &drm_encoder_slave. The field will be initialized with the hooks provided by the slave driver.

If ->platform_data is non-NULL it will be used as the initial slave config.

Returns 0 on success or a negative errno on failure, in particular, -ENODEV is returned when no matching driver is found.

Definition at line 52 of file drm_encoder_slave.c.