drivers/gpu/drm/mediatek/mtk_drm_drv.c
Source file repositories/reference/linux-study-clean/drivers/gpu/drm/mediatek/mtk_drm_drv.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpu/drm/mediatek/mtk_drm_drv.c- Extension
.c- Size
- 35930 bytes
- Lines
- 1306
- Domain
- Driver Families
- Bucket
- drivers/gpu
- Inferred role
- Driver Families: exported/initcall integration point
- Status
- integration 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.
- Exports symbols or registers init work; inspect boot/module ordering and who consumes the exported contract.
- 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/aperture.hlinux/component.hlinux/module.hlinux/of.hlinux/of_platform.hlinux/platform_device.hlinux/pm_runtime.hlinux/dma-mapping.hdrm/clients/drm_client_setup.hdrm/drm_atomic.hdrm/drm_atomic_helper.hdrm/drm_drv.hdrm/drm_fbdev_dma.hdrm/drm_fourcc.hdrm/drm_gem.hdrm/drm_gem_dma_helper.hdrm/drm_gem_framebuffer_helper.hdrm/drm_ioctl.hdrm/drm_of.hdrm/drm_probe_helper.hdrm/drm_vblank.hmtk_crtc.hmtk_ddp_comp.hmtk_disp_drv.hmtk_drm_drv.h
Detected Declarations
function mtk_drm_mode_fb_createfunction mtk_drm_matchfunction mtk_drm_get_all_drm_privfunction for_each_child_of_nodefunction mtk_drm_find_mmsys_compfunction mtk_drm_kms_initfunction mtk_drm_kms_deinitfunction compare_devfunction mtk_drm_bindfunction mtk_drm_unbindfunction mtk_drm_of_get_ddp_comp_typefunction mtk_drm_of_get_ddp_ep_cidfunction mtk_drm_of_ddp_path_build_onefunction mtk_drm_of_ddp_path_buildfunction for_each_endpoint_of_nodefunction mtk_drm_probefunction mtk_drm_removefunction mtk_drm_shutdownfunction mtk_drm_sys_preparefunction mtk_drm_sys_completefunction mtk_drm_initfunction mtk_drm_exitmodule init mtk_drm_init
Annotated Snippet
module_init(mtk_drm_init);
module_exit(mtk_drm_exit);
MODULE_AUTHOR("YT SHEN <yt.shen@mediatek.com>");
MODULE_DESCRIPTION("Mediatek SoC DRM driver");
MODULE_LICENSE("GPL v2");
Annotation
- Immediate include surface: `linux/aperture.h`, `linux/component.h`, `linux/module.h`, `linux/of.h`, `linux/of_platform.h`, `linux/platform_device.h`, `linux/pm_runtime.h`, `linux/dma-mapping.h`.
- Detected declarations: `function mtk_drm_mode_fb_create`, `function mtk_drm_match`, `function mtk_drm_get_all_drm_priv`, `function for_each_child_of_node`, `function mtk_drm_find_mmsys_comp`, `function mtk_drm_kms_init`, `function mtk_drm_kms_deinit`, `function compare_dev`, `function mtk_drm_bind`, `function mtk_drm_unbind`.
- Atlas domain: Driver Families / drivers/gpu.
- Implementation status: integration 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.