drivers/gpu/drm/xe/display/xe_frontbuffer.c
Source file repositories/reference/linux-study-clean/drivers/gpu/drm/xe/display/xe_frontbuffer.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpu/drm/xe/display/xe_frontbuffer.c- Extension
.c- Size
- 1534 bytes
- Lines
- 72
- 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.
- 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
drm/drm_gem.hdrm/intel/display_parent_interface.hintel_frontbuffer.hxe_frontbuffer.h
Detected Declarations
struct xe_frontbufferfunction xe_frontbuffer_reffunction frontbuffer_releasefunction xe_frontbuffer_putfunction xe_frontbuffer_flush_for_display
Annotated Snippet
struct xe_frontbuffer {
struct intel_frontbuffer base;
struct drm_gem_object *obj;
struct kref ref;
};
static struct intel_frontbuffer *xe_frontbuffer_get(struct drm_gem_object *obj)
{
struct xe_frontbuffer *front;
front = kmalloc_obj(*front);
if (!front)
return NULL;
intel_frontbuffer_init(&front->base, obj->dev);
kref_init(&front->ref);
drm_gem_object_get(obj);
front->obj = obj;
return &front->base;
}
static void xe_frontbuffer_ref(struct intel_frontbuffer *_front)
{
struct xe_frontbuffer *front =
container_of(_front, typeof(*front), base);
kref_get(&front->ref);
}
static void frontbuffer_release(struct kref *ref)
{
struct xe_frontbuffer *front =
container_of(ref, typeof(*front), ref);
intel_frontbuffer_fini(&front->base);
drm_gem_object_put(front->obj);
kfree(front);
}
static void xe_frontbuffer_put(struct intel_frontbuffer *_front)
{
struct xe_frontbuffer *front =
container_of(_front, typeof(*front), base);
kref_put(&front->ref, frontbuffer_release);
}
static void xe_frontbuffer_flush_for_display(struct intel_frontbuffer *front)
{
}
const struct intel_display_frontbuffer_interface xe_display_frontbuffer_interface = {
.get = xe_frontbuffer_get,
.ref = xe_frontbuffer_ref,
.put = xe_frontbuffer_put,
.flush_for_display = xe_frontbuffer_flush_for_display,
};
Annotation
- Immediate include surface: `drm/drm_gem.h`, `drm/intel/display_parent_interface.h`, `intel_frontbuffer.h`, `xe_frontbuffer.h`.
- Detected declarations: `struct xe_frontbuffer`, `function xe_frontbuffer_ref`, `function frontbuffer_release`, `function xe_frontbuffer_put`, `function xe_frontbuffer_flush_for_display`.
- Atlas domain: Driver Families / drivers/gpu.
- Implementation status: source implementation candidate.
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.