drivers/gpu/drm/i915/display/intel_fb.c
Source file repositories/reference/linux-study-clean/drivers/gpu/drm/i915/display/intel_fb.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpu/drm/i915/display/intel_fb.c- Extension
.c- Size
- 73273 bytes
- Lines
- 2408
- 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/dma-fence.hlinux/dma-resv.hdrm/drm_blend.hdrm/drm_gem.hdrm/drm_modeset_helper.hdrm/drm_print.hintel_bo.hintel_display.hintel_display_core.hintel_display_types.hintel_display_utils.hintel_fb.hintel_frontbuffer.hintel_parent.hintel_plane.h
Detected Declarations
struct intel_modifier_descstruct fb_plane_view_dimsstruct frontbuffer_fence_cbfunction lookup_format_infofunction intel_fb_modifier_to_tilingfunction intel_fb_get_format_infofunction plane_caps_contain_anyfunction plane_caps_contain_allfunction intel_fb_is_tiled_modifierfunction intel_fb_is_ccs_modifierfunction intel_fb_is_rc_ccs_cc_modifierfunction intel_fb_is_mc_ccs_modifierfunction intel_fb_needs_64k_physfunction intel_fb_needs_cpu_accessfunction intel_fb_is_tile4_modifierfunction check_modifier_display_ver_rangefunction plane_has_modifierfunction intel_fb_plane_supports_modifierfunction format_is_yuv_semiplanarfunction intel_format_info_is_yuv_semiplanarfunction ccs_aux_plane_maskfunction intel_fb_is_ccs_aux_planefunction intel_fb_is_gen12_ccs_aux_planefunction intel_fb_rc_ccs_cc_planefunction is_gen12_ccs_cc_planefunction is_surface_linearfunction main_to_ccs_planefunction skl_ccs_to_main_planefunction gen12_ccs_aux_stridefunction skl_main_to_aux_planefunction intel_tile_sizefunction intel_tile_width_bytesfunction intel_tile_heightfunction intel_tile_dimsfunction intel_tile_block_dimsfunction intel_fb_align_heightfunction intel_fb_modifier_uses_dptfunction intel_fb_uses_dptfunction intel_fb_plane_get_subsamplingfunction intel_fb_plane_dimsfunction intel_adjust_tile_offsetfunction intel_adjust_linear_offsetfunction intel_adjust_aligned_offsetfunction intel_plane_adjust_aligned_offsetfunction intel_compute_aligned_offsetfunction intel_plane_compute_aligned_offsetfunction intel_fb_offset_to_xyfunction intel_fb_check_ccs_xy
Annotated Snippet
struct intel_modifier_desc {
u64 modifier;
struct {
u8 from;
u8 until;
} display_ver;
#define DISPLAY_VER_ALL { 0, -1 }
const struct drm_format_info *formats;
int format_count;
#define FORMAT_OVERRIDE(format_list) \
.formats = format_list, \
.format_count = ARRAY_SIZE(format_list)
u8 plane_caps;
struct {
u8 cc_planes:3;
u8 packed_aux_planes:4;
u8 planar_aux_planes:4;
} ccs;
};
#define INTEL_PLANE_CAP_CCS_MASK (INTEL_PLANE_CAP_CCS_RC | \
INTEL_PLANE_CAP_CCS_RC_CC | \
INTEL_PLANE_CAP_CCS_MC)
#define INTEL_PLANE_CAP_TILING_MASK (INTEL_PLANE_CAP_TILING_X | \
INTEL_PLANE_CAP_TILING_Y | \
INTEL_PLANE_CAP_TILING_Yf | \
INTEL_PLANE_CAP_TILING_4)
#define INTEL_PLANE_CAP_TILING_NONE 0
static const struct intel_modifier_desc intel_modifiers[] = {
{
.modifier = I915_FORMAT_MOD_4_TILED_LNL_CCS,
.display_ver = { 20, -1 },
.plane_caps = INTEL_PLANE_CAP_TILING_4,
}, {
.modifier = I915_FORMAT_MOD_4_TILED_BMG_CCS,
.display_ver = { 14, -1 },
.plane_caps = INTEL_PLANE_CAP_TILING_4 | INTEL_PLANE_CAP_NEED64K_PHYS,
}, {
.modifier = I915_FORMAT_MOD_4_TILED_MTL_MC_CCS,
.display_ver = { 14, 14 },
.plane_caps = INTEL_PLANE_CAP_TILING_4 | INTEL_PLANE_CAP_CCS_MC,
.ccs.packed_aux_planes = BIT(1),
.ccs.planar_aux_planes = BIT(2) | BIT(3),
FORMAT_OVERRIDE(gen12_ccs_formats),
}, {
.modifier = I915_FORMAT_MOD_4_TILED_MTL_RC_CCS,
.display_ver = { 14, 14 },
.plane_caps = INTEL_PLANE_CAP_TILING_4 | INTEL_PLANE_CAP_CCS_RC,
.ccs.packed_aux_planes = BIT(1),
FORMAT_OVERRIDE(gen12_ccs_formats),
}, {
.modifier = I915_FORMAT_MOD_4_TILED_MTL_RC_CCS_CC,
.display_ver = { 14, 14 },
.plane_caps = INTEL_PLANE_CAP_TILING_4 | INTEL_PLANE_CAP_CCS_RC_CC,
.ccs.cc_planes = BIT(2),
.ccs.packed_aux_planes = BIT(1),
FORMAT_OVERRIDE(gen12_ccs_cc_formats),
}, {
.modifier = I915_FORMAT_MOD_4_TILED_DG2_MC_CCS,
.display_ver = { 13, 13 },
.plane_caps = INTEL_PLANE_CAP_TILING_4 | INTEL_PLANE_CAP_CCS_MC,
}, {
.modifier = I915_FORMAT_MOD_4_TILED_DG2_RC_CCS_CC,
.display_ver = { 13, 13 },
.plane_caps = INTEL_PLANE_CAP_TILING_4 | INTEL_PLANE_CAP_CCS_RC_CC,
.ccs.cc_planes = BIT(1),
FORMAT_OVERRIDE(gen12_flat_ccs_cc_formats),
}, {
.modifier = I915_FORMAT_MOD_4_TILED_DG2_RC_CCS,
.display_ver = { 13, 13 },
.plane_caps = INTEL_PLANE_CAP_TILING_4 | INTEL_PLANE_CAP_CCS_RC,
}, {
.modifier = I915_FORMAT_MOD_4_TILED,
.display_ver = { 13, -1 },
.plane_caps = INTEL_PLANE_CAP_TILING_4,
}, {
.modifier = I915_FORMAT_MOD_Y_TILED_GEN12_MC_CCS,
.display_ver = { 12, 13 },
Annotation
- Immediate include surface: `linux/dma-fence.h`, `linux/dma-resv.h`, `drm/drm_blend.h`, `drm/drm_gem.h`, `drm/drm_modeset_helper.h`, `drm/drm_print.h`, `intel_bo.h`, `intel_display.h`.
- Detected declarations: `struct intel_modifier_desc`, `struct fb_plane_view_dims`, `struct frontbuffer_fence_cb`, `function lookup_format_info`, `function intel_fb_modifier_to_tiling`, `function intel_fb_get_format_info`, `function plane_caps_contain_any`, `function plane_caps_contain_all`, `function intel_fb_is_tiled_modifier`, `function intel_fb_is_ccs_modifier`.
- 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.