Linux Kernel
3.7.1
|
#include <drm/drmP.h>
Go to the source code of this file.
Data Structures | |
struct | drm_buffer |
Functions | |
int | drm_buffer_alloc (struct drm_buffer **buf, int size) |
int | drm_buffer_copy_from_user (struct drm_buffer *buf, void __user *user_data, int size) |
void | drm_buffer_free (struct drm_buffer *buf) |
void * | drm_buffer_read_object (struct drm_buffer *buf, int objsize, void *stack_obj) |
int drm_buffer_alloc | ( | struct drm_buffer ** | buf, |
int | size | ||
) |
void drm_buffer_free | ( | struct drm_buffer * | buf | ) |
Free the drm buffer object
Definition at line 135 of file drm_buffer.c.
void* drm_buffer_read_object | ( | struct drm_buffer * | buf, |
int | objsize, | ||
void * | stack_obj | ||
) |
Read an object from buffer that may be split to multiple parts. If object is not split function just returns the pointer to object in buffer. But in case of split object data is copied to given stack object that is suplied by caller.
The processing location of the buffer is also advanced to the next byte after the object.
objsize: The size of the objet in bytes. stack_obj: A pointer to a memory location where object can be copied.
Definition at line 162 of file drm_buffer.c.