drivers/gpu/drm/vmwgfx/vmwgfx_kms.h
Source file repositories/reference/linux-study-clean/drivers/gpu/drm/vmwgfx/vmwgfx_kms.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpu/drm/vmwgfx/vmwgfx_kms.h- Extension
.h- Size
- 16185 bytes
- Lines
- 516
- Domain
- Driver Families
- Bucket
- drivers/gpu
- Inferred role
- Driver Families: implementation source
- Status
- source implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
vmwgfx_cursor_plane.hvmwgfx_drv.hdrm/drm_encoder.hdrm/drm_framebuffer.hdrm/drm_probe_helper.h
Detected Declarations
struct vmw_du_update_planestruct vmw_du_update_plane_surfacestruct vmw_du_update_plane_bufferstruct vmw_kms_dirtystruct vmw_framebufferstruct vmw_framebuffer_surfacestruct vmw_framebuffer_bostruct vmw_crtc_statestruct vmw_plane_statestruct vmw_connector_statestruct vmw_display_unitfunction vmw_du_translate_to_crtc
Annotated Snippet
struct vmw_du_update_plane {
/**
* @calc_fifo_size: Calculate fifo size.
*
* Determine fifo size for the commands needed for update. The number of
* damage clips on display unit @num_hits will be passed to allocate
* sufficient fifo space.
*
* Return: Fifo size needed
*/
uint32_t (*calc_fifo_size)(struct vmw_du_update_plane *update,
uint32_t num_hits);
/**
* @post_prepare: Populate fifo for resource preparation.
*
* Some surface resource or buffer object need some extra cmd submission
* like update GB image for proxy surface and define a GMRFB for screen
* object. That should be done here as this callback will be
* called after FIFO allocation with the address of command buufer.
*
* This callback is optional.
*
* Return: Size of commands populated to command buffer.
*/
uint32_t (*post_prepare)(struct vmw_du_update_plane *update, void *cmd);
/**
* @pre_clip: Populate fifo before clip.
*
* This is where pre clip related command should be populated like
* surface copy/DMA, etc.
*
* This callback is optional.
*
* Return: Size of commands populated to command buffer.
*/
uint32_t (*pre_clip)(struct vmw_du_update_plane *update, void *cmd,
uint32_t num_hits);
/**
* @clip: Populate fifo for clip.
*
* This is where to populate clips for surface copy/dma or blit commands
* if needed. This will be called times have damage in display unit,
* which is one if doing full update. @clip is the damage in destination
* coordinates which is crtc/DU and @src_x, @src_y is damage clip src in
* framebuffer coordinate.
*
* This callback is optional.
*
* Return: Size of commands populated to command buffer.
*/
uint32_t (*clip)(struct vmw_du_update_plane *update, void *cmd,
struct drm_rect *clip, uint32_t src_x, uint32_t src_y);
/**
* @post_clip: Populate fifo after clip.
*
* This is where to populate display unit update commands or blit
* commands.
*
* Return: Size of commands populated to command buffer.
*/
uint32_t (*post_clip)(struct vmw_du_update_plane *update, void *cmd,
struct drm_rect *bb);
struct drm_plane *plane;
struct drm_plane_state *old_state;
struct vmw_private *dev_priv;
struct vmw_display_unit *du;
struct vmw_framebuffer *vfb;
struct vmw_fence_obj **out_fence;
struct mutex *mutex;
bool intr;
};
/**
* struct vmw_du_update_plane_surface - closure structure for surface
* @base: base closure structure.
* @cmd_start: FIFO command start address (used by SOU only).
*/
struct vmw_du_update_plane_surface {
struct vmw_du_update_plane base;
/* This member is to handle special case SOU surface update */
void *cmd_start;
};
/**
* struct vmw_du_update_plane_buffer - Closure structure for buffer object
Annotation
- Immediate include surface: `vmwgfx_cursor_plane.h`, `vmwgfx_drv.h`, `drm/drm_encoder.h`, `drm/drm_framebuffer.h`, `drm/drm_probe_helper.h`.
- Detected declarations: `struct vmw_du_update_plane`, `struct vmw_du_update_plane_surface`, `struct vmw_du_update_plane_buffer`, `struct vmw_kms_dirty`, `struct vmw_framebuffer`, `struct vmw_framebuffer_surface`, `struct vmw_framebuffer_bo`, `struct vmw_crtc_state`, `struct vmw_plane_state`, `struct vmw_connector_state`.
- Atlas domain: Driver Families / drivers/gpu.
- Implementation status: source implementation candidate.
- Synchronization appears in or near this file; preserve lock ordering, sleepability, and interrupt-context constraints.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.