Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
vmwgfx_kms.c File Reference
#include "vmwgfx_kms.h"

Go to the source code of this file.

Data Structures

struct  vmw_clip_rect
 
struct  vmw_framebuffer_surface
 
struct  vmw_framebuffer_dmabuf
 

Macros

#define VMWGFX_PRESENT_RATE   ((HZ / 60 > 0) ? HZ / 60 : 1)
 
#define vmw_framebuffer_to_vfbs(x)   container_of(x, struct vmw_framebuffer_surface, base.base)
 
#define vmw_framebuffer_to_vfbd(x)   container_of(x, struct vmw_framebuffer_dmabuf, base.base)
 

Functions

void vmw_clip_cliprects (struct drm_clip_rect *rects, int num_rects, struct vmw_clip_rect clip, SVGASignedRect *out_rects, int *out_num)
 
void vmw_display_unit_cleanup (struct vmw_display_unit *du)
 
int vmw_cursor_update_image (struct vmw_private *dev_priv, u32 *image, u32 width, u32 height, u32 hotspotX, u32 hotspotY)
 
int vmw_cursor_update_dmabuf (struct vmw_private *dev_priv, struct vmw_dma_buffer *dmabuf, u32 width, u32 height, u32 hotspotX, u32 hotspotY)
 
void vmw_cursor_update_position (struct vmw_private *dev_priv, bool show, int x, int y)
 
int vmw_du_crtc_cursor_set (struct drm_crtc *crtc, struct drm_file *file_priv, uint32_t handle, uint32_t width, uint32_t height)
 
int vmw_du_crtc_cursor_move (struct drm_crtc *crtc, int x, int y)
 
void vmw_kms_cursor_snoop (struct vmw_surface *srf, struct ttm_object_file *tfile, struct ttm_buffer_object *bo, SVGA3dCmdHeader *header)
 
void vmw_kms_cursor_post_execbuf (struct vmw_private *dev_priv)
 
int vmw_framebuffer_create_handle (struct drm_framebuffer *fb, struct drm_file *file_priv, unsigned int *handle)
 
void vmw_framebuffer_surface_destroy (struct drm_framebuffer *framebuffer)
 
int vmw_framebuffer_surface_dirty (struct drm_framebuffer *framebuffer, struct drm_file *file_priv, unsigned flags, unsigned color, struct drm_clip_rect *clips, unsigned num_clips)
 
void vmw_framebuffer_dmabuf_destroy (struct drm_framebuffer *framebuffer)
 
int vmw_framebuffer_dmabuf_dirty (struct drm_framebuffer *framebuffer, struct drm_file *file_priv, unsigned flags, unsigned color, struct drm_clip_rect *clips, unsigned num_clips)
 
int vmw_kms_present (struct vmw_private *dev_priv, struct drm_file *file_priv, struct vmw_framebuffer *vfb, struct vmw_surface *surface, uint32_t sid, int32_t destX, int32_t destY, struct drm_vmw_rect *clips, uint32_t num_clips)
 
int vmw_kms_readback (struct vmw_private *dev_priv, struct drm_file *file_priv, struct vmw_framebuffer *vfb, struct drm_vmw_fence_rep __user *user_fence_rep, struct drm_vmw_rect *clips, uint32_t num_clips)
 
int vmw_kms_init (struct vmw_private *dev_priv)
 
int vmw_kms_close (struct vmw_private *dev_priv)
 
int vmw_kms_cursor_bypass_ioctl (struct drm_device *dev, void *data, struct drm_file *file_priv)
 
int vmw_kms_write_svga (struct vmw_private *vmw_priv, unsigned width, unsigned height, unsigned pitch, unsigned bpp, unsigned depth)
 
int vmw_kms_save_vga (struct vmw_private *vmw_priv)
 
int vmw_kms_restore_vga (struct vmw_private *vmw_priv)
 
bool vmw_kms_validate_mode_vram (struct vmw_private *dev_priv, uint32_t pitch, uint32_t height)
 
u32 vmw_get_vblank_counter (struct drm_device *dev, int crtc)
 
int vmw_enable_vblank (struct drm_device *dev, int crtc)
 
void vmw_disable_vblank (struct drm_device *dev, int crtc)
 
int vmw_du_update_layout (struct vmw_private *dev_priv, unsigned num, struct drm_vmw_rect *rects)
 
int vmw_du_page_flip (struct drm_crtc *crtc, struct drm_framebuffer *fb, struct drm_pending_vblank_event *event)
 
void vmw_du_crtc_save (struct drm_crtc *crtc)
 
void vmw_du_crtc_restore (struct drm_crtc *crtc)
 
void vmw_du_crtc_gamma_set (struct drm_crtc *crtc, u16 *r, u16 *g, u16 *b, uint32_t start, uint32_t size)
 
void vmw_du_connector_dpms (struct drm_connector *connector, int mode)
 
void vmw_du_connector_save (struct drm_connector *connector)
 
void vmw_du_connector_restore (struct drm_connector *connector)
 
enum drm_connector_status vmw_du_connector_detect (struct drm_connector *connector, bool force)
 
int vmw_du_connector_fill_modes (struct drm_connector *connector, uint32_t max_width, uint32_t max_height)
 
int vmw_du_connector_set_property (struct drm_connector *connector, struct drm_property *property, uint64_t val)
 
int vmw_kms_update_layout_ioctl (struct drm_device *dev, void *data, struct drm_file *file_priv)
 

Macro Definition Documentation

#define vmw_framebuffer_to_vfbd (   x)    container_of(x, struct vmw_framebuffer_dmabuf, base.base)

Definition at line 724 of file vmwgfx_kms.c.

#define vmw_framebuffer_to_vfbs (   x)    container_of(x, struct vmw_framebuffer_surface, base.base)

Definition at line 390 of file vmwgfx_kms.c.

#define VMWGFX_PRESENT_RATE   ((HZ / 60 > 0) ? HZ / 60 : 1)

Definition at line 32 of file vmwgfx_kms.c.

Function Documentation

void vmw_clip_cliprects ( struct drm_clip_rect rects,
int  num_rects,
struct vmw_clip_rect  clip,
SVGASignedRect out_rects,
int out_num 
)

Clip number of against storing the results in and the number of passed rects in .

Definition at line 43 of file vmwgfx_kms.c.

int vmw_cursor_update_dmabuf ( struct vmw_private dev_priv,
struct vmw_dma_buffer dmabuf,
u32  width,
u32  height,
u32  hotspotX,
u32  hotspotY 
)

Definition at line 123 of file vmwgfx_kms.c.

int vmw_cursor_update_image ( struct vmw_private dev_priv,
u32 image,
u32  width,
u32  height,
u32  hotspotX,
u32  hotspotY 
)

Definition at line 87 of file vmwgfx_kms.c.

void vmw_cursor_update_position ( struct vmw_private dev_priv,
bool  show,
int  x,
int  y 
)

Definition at line 160 of file vmwgfx_kms.c.

void vmw_disable_vblank ( struct drm_device dev,
int  crtc 
)

Function called by DRM code called with vbl_lock held.

Definition at line 1632 of file vmwgfx_kms.c.

void vmw_display_unit_cleanup ( struct vmw_display_unit du)

Definition at line 72 of file vmwgfx_kms.c.

enum drm_connector_status vmw_du_connector_detect ( struct drm_connector connector,
bool  force 
)

Definition at line 1788 of file vmwgfx_kms.c.

void vmw_du_connector_dpms ( struct drm_connector connector,
int  mode 
)

Definition at line 1775 of file vmwgfx_kms.c.

int vmw_du_connector_fill_modes ( struct drm_connector connector,
uint32_t  max_width,
uint32_t  max_height 
)

Definition at line 1903 of file vmwgfx_kms.c.

void vmw_du_connector_restore ( struct drm_connector connector)

Definition at line 1783 of file vmwgfx_kms.c.

void vmw_du_connector_save ( struct drm_connector connector)

Definition at line 1779 of file vmwgfx_kms.c.

int vmw_du_connector_set_property ( struct drm_connector connector,
struct drm_property property,
uint64_t  val 
)

Definition at line 1971 of file vmwgfx_kms.c.

int vmw_du_crtc_cursor_move ( struct drm_crtc crtc,
int  x,
int  y 
)

Definition at line 238 of file vmwgfx_kms.c.

int vmw_du_crtc_cursor_set ( struct drm_crtc crtc,
struct drm_file *  file_priv,
uint32_t  handle,
uint32_t  width,
uint32_t  height 
)

Definition at line 173 of file vmwgfx_kms.c.

void vmw_du_crtc_gamma_set ( struct drm_crtc crtc,
u16 r,
u16 g,
u16 b,
uint32_t  start,
uint32_t  size 
)

Definition at line 1759 of file vmwgfx_kms.c.

void vmw_du_crtc_restore ( struct drm_crtc crtc)

Definition at line 1755 of file vmwgfx_kms.c.

void vmw_du_crtc_save ( struct drm_crtc crtc)

Definition at line 1751 of file vmwgfx_kms.c.

int vmw_du_page_flip ( struct drm_crtc crtc,
struct drm_framebuffer fb,
struct drm_pending_vblank_event *  event 
)

Definition at line 1683 of file vmwgfx_kms.c.

int vmw_du_update_layout ( struct vmw_private dev_priv,
unsigned  num,
struct drm_vmw_rect rects 
)

Definition at line 1641 of file vmwgfx_kms.c.

int vmw_enable_vblank ( struct drm_device dev,
int  crtc 
)

Function called by DRM code called with vbl_lock held.

Definition at line 1624 of file vmwgfx_kms.c.

int vmw_framebuffer_create_handle ( struct drm_framebuffer fb,
struct drm_file *  file_priv,
unsigned int handle 
)

Definition at line 376 of file vmwgfx_kms.c.

void vmw_framebuffer_dmabuf_destroy ( struct drm_framebuffer framebuffer)

Definition at line 732 of file vmwgfx_kms.c.

int vmw_framebuffer_dmabuf_dirty ( struct drm_framebuffer framebuffer,
struct drm_file *  file_priv,
unsigned  flags,
unsigned  color,
struct drm_clip_rect clips,
unsigned  num_clips 
)

Definition at line 918 of file vmwgfx_kms.c.

void vmw_framebuffer_surface_destroy ( struct drm_framebuffer framebuffer)

Definition at line 401 of file vmwgfx_kms.c.

int vmw_framebuffer_surface_dirty ( struct drm_framebuffer framebuffer,
struct drm_file *  file_priv,
unsigned  flags,
unsigned  color,
struct drm_clip_rect clips,
unsigned  num_clips 
)

Definition at line 567 of file vmwgfx_kms.c.

u32 vmw_get_vblank_counter ( struct drm_device dev,
int  crtc 
)

Function called by DRM code called with vbl_lock held.

Definition at line 1616 of file vmwgfx_kms.c.

int vmw_kms_close ( struct vmw_private dev_priv)

Definition at line 1447 of file vmwgfx_kms.c.

int vmw_kms_cursor_bypass_ioctl ( struct drm_device dev,
void data,
struct drm_file *  file_priv 
)

Definition at line 1462 of file vmwgfx_kms.c.

void vmw_kms_cursor_post_execbuf ( struct vmw_private dev_priv)

Definition at line 349 of file vmwgfx_kms.c.

void vmw_kms_cursor_snoop ( struct vmw_surface srf,
struct ttm_object_file tfile,
struct ttm_buffer_object bo,
SVGA3dCmdHeader header 
)

Definition at line 254 of file vmwgfx_kms.c.

int vmw_kms_init ( struct vmw_private dev_priv)

Kernel modesetting - vmwgfx_kms.c

Definition at line 1427 of file vmwgfx_kms.c.

int vmw_kms_present ( struct vmw_private dev_priv,
struct drm_file *  file_priv,
struct vmw_framebuffer vfb,
struct vmw_surface surface,
uint32_t  sid,
int32_t  destX,
int32_t  destY,
struct drm_vmw_rect clips,
uint32_t  num_clips 
)

Definition at line 1184 of file vmwgfx_kms.c.

int vmw_kms_readback ( struct vmw_private dev_priv,
struct drm_file *  file_priv,
struct vmw_framebuffer vfb,
struct drm_vmw_fence_rep __user user_fence_rep,
struct drm_vmw_rect clips,
uint32_t  num_clips 
)

Definition at line 1320 of file vmwgfx_kms.c.

int vmw_kms_restore_vga ( struct vmw_private vmw_priv)

Definition at line 1573 of file vmwgfx_kms.c.

int vmw_kms_save_vga ( struct vmw_private vmw_priv)

Definition at line 1524 of file vmwgfx_kms.c.

int vmw_kms_update_layout_ioctl ( struct drm_device dev,
void data,
struct drm_file *  file_priv 
)

Definition at line 1979 of file vmwgfx_kms.c.

bool vmw_kms_validate_mode_vram ( struct vmw_private dev_priv,
uint32_t  pitch,
uint32_t  height 
)

Definition at line 1605 of file vmwgfx_kms.c.

int vmw_kms_write_svga ( struct vmw_private vmw_priv,
unsigned  width,
unsigned  height,
unsigned  pitch,
unsigned  bpp,
unsigned  depth 
)

Definition at line 1503 of file vmwgfx_kms.c.