drivers/gpu/drm/rockchip/rockchip_drm_fb.c
Source file repositories/reference/linux-study-clean/drivers/gpu/drm/rockchip/rockchip_drm_fb.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpu/drm/rockchip/rockchip_drm_fb.c- Extension
.c- Size
- 2256 bytes
- Lines
- 86
- 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.
- Allocates kernel memory; connect allocation flags and lifetime to context constraints.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/kernel.hdrm/drm.hdrm/drm_atomic.hdrm/drm_damage_helper.hdrm/drm_fourcc.hdrm/drm_framebuffer.hdrm/drm_gem_framebuffer_helper.hdrm/drm_probe_helper.hrockchip_drm_drv.hrockchip_drm_fb.hrockchip_drm_gem.h
Detected Declarations
function rockchip_fb_createfunction rockchip_drm_mode_config_init
Annotated Snippet
if (ret) {
drm_framebuffer_put(&afbc_fb->base);
return ERR_PTR(ret);
}
}
return &afbc_fb->base;
}
static const struct drm_mode_config_funcs rockchip_drm_mode_config_funcs = {
.fb_create = rockchip_fb_create,
.atomic_check = drm_atomic_helper_check,
.atomic_commit = drm_atomic_helper_commit,
};
void rockchip_drm_mode_config_init(struct drm_device *dev)
{
dev->mode_config.min_width = 0;
dev->mode_config.min_height = 0;
/*
* set max width and height as default value(4096x4096).
* this value would be used to check framebuffer size limitation
* at drm_mode_addfb().
*/
dev->mode_config.max_width = 4096;
dev->mode_config.max_height = 4096;
dev->mode_config.funcs = &rockchip_drm_mode_config_funcs;
dev->mode_config.helper_private = &rockchip_mode_config_helpers;
dev->mode_config.normalize_zpos = true;
}
Annotation
- Immediate include surface: `linux/kernel.h`, `drm/drm.h`, `drm/drm_atomic.h`, `drm/drm_damage_helper.h`, `drm/drm_fourcc.h`, `drm/drm_framebuffer.h`, `drm/drm_gem_framebuffer_helper.h`, `drm/drm_probe_helper.h`.
- Detected declarations: `function rockchip_fb_create`, `function rockchip_drm_mode_config_init`.
- 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.